From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from firstgate.proxmox.com (firstgate.proxmox.com [212.224.123.68]) by lore.proxmox.com (Postfix) with ESMTPS id 22F431FF13B for ; Wed, 08 Apr 2026 11:44:39 +0200 (CEST) Received: from firstgate.proxmox.com (localhost [127.0.0.1]) by firstgate.proxmox.com (Proxmox) with ESMTP id 893C96E74; Wed, 8 Apr 2026 11:45:14 +0200 (CEST) Message-ID: <56ac21cf-21eb-4822-835e-3c6ae306bff6@proxmox.com> Date: Wed, 8 Apr 2026 11:44:34 +0200 MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Beta Subject: Re: [PATCH yew-widget-toolkit v3] widget: add 'div', 'span' and 'italic' helper functions To: Robert Obkircher , Shannon Sterz , yew-devel@lists.proxmox.com, Dietmar Maurer References: <20260407130919.3451837-1-d.csapak@proxmox.com> <810066b0-7803-4eb5-9146-84847a6d8e6c@proxmox.com> Content-Language: en-US From: Dominik Csapak In-Reply-To: Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-Bm-Milter-Handled: 55990f41-d878-4baa-be0a-ee34c49e34d2 X-Bm-Transport-Timestamp: 1775641407611 X-SPAM-LEVEL: Spam detection results: 0 AWL 0.048 Adjusted score from AWL reputation of From: address BAYES_00 -1.9 Bayes spam probability is 0 to 1% DMARC_MISSING 0.1 Missing DMARC policy KAM_DMARC_STATUS 0.01 Test Rule for DKIM or SPF Failure with Strict Alignment RCVD_IN_VALIDITY_CERTIFIED_BLOCKED 0.001 ADMINISTRATOR NOTICE: The query to Validity was blocked. See https://knowledge.validity.com/hc/en-us/articles/20961730681243 for more information. RCVD_IN_VALIDITY_RPBL_BLOCKED 0.001 ADMINISTRATOR NOTICE: The query to Validity was blocked. See https://knowledge.validity.com/hc/en-us/articles/20961730681243 for more information. RCVD_IN_VALIDITY_SAFE_BLOCKED 0.001 ADMINISTRATOR NOTICE: The query to Validity was blocked. See https://knowledge.validity.com/hc/en-us/articles/20961730681243 for more information. SPF_HELO_NONE 0.001 SPF: HELO does not publish an SPF Record SPF_PASS -0.001 SPF: sender matches SPF record URIBL_BLOCKED 0.001 ADMINISTRATOR NOTICE: The query to URIBL was blocked. See http://wiki.apache.org/spamassassin/DnsBlocklists#dnsbl-block for more information. [mozilla.org] Message-ID-Hash: UPNO65C3XKYB3I5KJOSXKPCE2MJS3FW4 X-Message-ID-Hash: UPNO65C3XKYB3I5KJOSXKPCE2MJS3FW4 X-MailFrom: d.csapak@proxmox.com X-Mailman-Rule-Misses: dmarc-mitigation; no-senders; approved; loop; banned-address; emergency; member-moderation; nonmember-moderation; administrivia; implicit-dest; max-recipients; max-size; news-moderation; no-subject; digests; suspicious-header X-Mailman-Version: 3.3.10 Precedence: list List-Id: Yew framework devel list at Proxmox List-Help: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: On 4/8/26 10:57 AM, Robert Obkircher wrote: > > On 08.04.26 09:55, Shannon Sterz wrote: >> On Wed Apr 8, 2026 at 9:12 AM CEST, Dominik Csapak wrote: >>> >>> On 4/7/26 7:25 PM, Dietmar Maurer wrote: >>>> italic() is IMHO very missleading ... >>> On 4/7/26 5:04 PM, Shannon Sterz wrote: >>>> On Tue Apr 7, 2026 at 3:13 PM CEST, Dominik Csapak wrote: >>>>> ah, missed inserting the changelog, so here it is: >>>>> >>>>> changes from v2: >>>>> * use standalone functions instead of macro >>>>> * add span/italic too for convenience >>>>> * make container mod public >>>> one small thing that occured to me is that the `` element no longer >>>> is inteded for "italic text", but rather is a semantic element that >>>> should be used for "text that is set off from the normal prose for >>>> readability reasons" [1]. >>>> >>>> so it might be more appropriate to use a `span` with italic styling here >>>> or we could add helpers for other semantic text elements such as `` >>>> etc. too. no hard feelings on my side, though, i don't think this >>>> matters all too much. >>>> >>>> [1]: https://developer.mozilla.org/en-US/docs/Web/HTML/Reference/Elements/i#usage_notes >>>> >>>> but overall, looks good to me, so consider this: >>>> >>> >>> i actually didn't want to express the italic styling here, but wanted >>> to have the 'i' tag (since we use that often for icons and so on), >>> but didn't come up with a better name than 'italic'. I also didn't want >>> to add a single-letter function. >>> >>> does any of you have a better idea ? >>> >>> mdn calls it the "Idiomatic Text element" but 'idiomatic()' also does >>> not really convey what it does. >>> >>> I can of course leave it out for now and we can decide later. >> just to put a couple of ideas out there: keeping with the rest of the >> functions here would be `i()`, but that might be a bit too short. >> >> we could maybe have a naming convention for wrapper helpers like this >> like `i_element()`, `span_element()`, and `div_element()` (alternatively >> replace `element` with `container` or `wrapper`). that feels a bit >> unnecessarily verbose, though. > Or a module like `tag::i` to let the caller decide whether the > function should be imported directly. >> if the intention is for this to mostly be used with icons, maybe that is >> best handled separately? for example, with an `Icon` component that >> takes the appropriate icon classes. somewhat analogous to `ActionIcon` >> except without the interactive component. >> >> --> snip <-- >> >> >> >> I think I'll simply leave the i tag out for now. It's not necessary, and we could use our 'Fa' for most of the icons. i'll send a v4