[tw5] Re: Combobox idea

2021-11-14 Thread Télumire
With the content type text/css , tiddlywiki treats the content of the tiddler as plain text, and since I rely on wikitext parsing this breaks the stylesheet. You need to use the content type text/vnd.tiddlywiki or leave the type field blank (since this is the default type for a tiddler). I

[tw5] Re: Combobox idea

2021-11-14 Thread Mat
Thanks Télumire using your exact styling tiddler, but with an added type:text/css this is how it appears , i.e om my Win 10 machine using Chrome, Brave and Firefox I see a selectwidget but no visible button and you can't type into it. Same thing on my android

[tw5] Re: Combobox idea

2021-11-13 Thread Télumire
Hi @Mat, the apostrophes are intended, they prevent the wikitext parsing to convert the -- into – (the wikitext cant be disabled with a pragma rule or a content type in thatcase because this would prevent the use of widgets). Drag & drop this tiddler in your wiki and it should work fine (it

[tw5] Re: Combobox idea

2021-11-13 Thread Mat
@Télumire - I now tried to copy your code but it doesn't work properly. I've tried both from your attached tid file and using the copy-to-clipboard feature on your webpage but the code seems buggy e.g the -- prefix on css variables are enclosed in apostrophes. This is what I get

Re: [tw5] Re: Combobox idea

2021-11-05 Thread John D
Thanks @Mat! Sure, go ahead :) Le ven. 5 nov. 2021 à 08:51, Mat a écrit : > @Telumire - Man, that turned out quite ambitious. Looks great! Of course, > we're way past "I found a way to quickly throw together a combobox", but IF > one has the styles, perhaps as part of ones standard custom

[tw5] Re: Combobox idea

2021-11-05 Thread Mat
@Telumire - Man, that turned out quite ambitious. Looks great! Of course, we're way past "I found a way to quickly throw together a combobox", but IF one has the styles, perhaps as part of ones standard custom stylesheets, then it is only a matter applying it with @@.combobox. For the record,

[tw5] Re: Combobox idea

2021-11-04 Thread Télumire
Ok I think this time I got it. Here : https://Telumire.github.io/TiddlyTweaks/index.html#:%5B%5BCombobox%5D%5D Le jeudi 4 novembre 2021 à 23:17:51 UTC+1, Télumire a écrit : > > @Eric Shulman my bad, I should have tested it a bit more. Thanks for > pointing this out ! @Mat, this is because

[tw5] Re: Combobox idea

2021-11-04 Thread Télumire
@Eric Shulman my bad, I should have tested it a bit more. Thanks for pointing this out ! @Mat, this is because the select element is OS dependent according to this stack overflow answer : https://stackoverflow.com/a/1895485/11549574 This one can be used properly inline (with a text after and

[tw5] Re: Combobox idea

2021-11-04 Thread Mat
@Télumire, I appreciate your effort! @Eric, thank you for your shrewd analysis! Does anyone know why it is barely possible to manipulate this dropdown though? I do get the following to work, so the options *are* targettable: .select-btn option {background:red} ...but attempting to e.g

[tw5] Re: Combobox idea

2021-11-04 Thread Eric Shulman
On Thursday, November 4, 2021 at 12:31:14 PM UTC-7 Télumire wrote: > Here's the code to push the dropdown in the proper place : > There are layout problems with this solution. To see the issues, try putting "before" and "after" text surrounding the "combobox" span: > *BEFORE* > <$select

[tw5] Re: Combobox idea

2021-11-04 Thread Télumire
Here's the code to push the dropdown in the proper place : <$select field=selection class="select-btn" > A Tale of Two Cities A New Kind of Science The Dice Man <$edit-text field=selection placeholder="type or select"/> .combobox{ position:relative; display:inline-block; width:150px; }

[tw5] Re: Combobox idea

2021-11-04 Thread Mat
Thanks Eric. I also have other ways of achieving the end result, but with the direct editing of currentTiddler fields in TW 5.2.0 I thought I had come across a very simple solution for a simple combobox. However, some further experimenting shows that the lost focus was easily solved by just

[tw5] Re: Combobox idea

2021-11-04 Thread Eric Shulman
On Thursday, November 4, 2021 at 4:38:55 AM UTC-7 Mat wrote: > I just came up with a simple idea for how to create comboboxes. Basically > it is an EditTextWidget just before the SelectWidget and the select widget > is styled to only show the arrow and both widgets refer to the same field. >