From mboxrd@z Thu Jan  1 00:00:00 1970
Return-Path: <yew-devel-bounces@lists.proxmox.com>
Received: from firstgate.proxmox.com (firstgate.proxmox.com [212.224.123.68])
	by lore.proxmox.com (Postfix) with ESMTPS id 92DDE1FF15C
	for <inbox@lore.proxmox.com>; Wed, 22 Jan 2025 13:59:59 +0100 (CET)
Received: from firstgate.proxmox.com (localhost [127.0.0.1])
	by firstgate.proxmox.com (Proxmox) with ESMTP id CCB6B1E8AE;
	Wed, 22 Jan 2025 13:59:56 +0100 (CET)
Mime-Version: 1.0
Date: Wed, 22 Jan 2025 13:59:23 +0100
Message-Id: <D78MC95D2PHE.MOB9DVOQPFT5@proxmox.com>
From: "Shannon Sterz" <s.sterz@proxmox.com>
To: "Yew framework devel list at Proxmox" <yew-devel@lists.proxmox.com>
X-Mailer: aerc 0.18.2-0-ge037c095a049-dirty
References: <20250122121349.239939-1-m.sandoval@proxmox.com>
In-Reply-To: <20250122121349.239939-1-m.sandoval@proxmox.com>
X-SPAM-LEVEL: Spam detection results:  0
 AWL -0.181 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
 POISEN_SPAM_PILL          0.1 Meta: its spam
 POISEN_SPAM_PILL_1        0.1 random spam to be learned in bayes
 POISEN_SPAM_PILL_3        0.1 random spam to be learned in bayes
 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
Subject: Re: [yew-devel] [PATCH pywt] catalog_loader: fix url for
 translation files
X-BeenThere: yew-devel@lists.proxmox.com
X-Mailman-Version: 2.1.29
Precedence: list
List-Id: Yew framework devel list at Proxmox <yew-devel.lists.proxmox.com>
List-Unsubscribe: <https://lists.proxmox.com/cgi-bin/mailman/options/yew-devel>, 
 <mailto:yew-devel-request@lists.proxmox.com?subject=unsubscribe>
List-Archive: <http://lists.proxmox.com/pipermail/yew-devel/>
List-Post: <mailto:yew-devel@lists.proxmox.com>
List-Help: <mailto:yew-devel-request@lists.proxmox.com?subject=help>
List-Subscribe: <https://lists.proxmox.com/cgi-bin/mailman/listinfo/yew-devel>, 
 <mailto:yew-devel-request@lists.proxmox.com?subject=subscribe>
Reply-To: Yew framework devel list at Proxmox <yew-devel@lists.proxmox.com>
Content-Type: text/plain; charset="us-ascii"
Content-Transfer-Encoding: 7bit
Errors-To: yew-devel-bounces@lists.proxmox.com
Sender: "yew-devel" <yew-devel-bounces@lists.proxmox.com>

On Wed Jan 22, 2025 at 1:13 PM CET, Maximiliano Sandoval wrote:
> As per proxmox-datacenter-api.rs:
> ```rust
>             ("locale", "/usr/share/pdm-i18n"),
> ```
> the translations are at /locale/catalog-{lang}.mo
>
> Signed-off-by: Maximiliano Sandoval <m.sandoval@proxmox.com>
> ---
>  src/widget/catalog_loader.rs | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/src/widget/catalog_loader.rs b/src/widget/catalog_loader.rs
> index 21437991..c3732d49 100644
> --- a/src/widget/catalog_loader.rs
> +++ b/src/widget/catalog_loader.rs
> @@ -49,7 +49,7 @@ impl CatalogLoader {
>          if let Some(url_builder) = &self.url_builder {
>              url_builder.apply(&lang)
>          } else {
> -            format!("catalog-{}.mo", lang)
> +            format!("locale/catalog-{lang}.mo")
>          }
>      }
>  }

this re-defines the fallback here. i'd rather you give this catalog
loader an `url_builder` as that is the already implemented way of
adapting the location of catalogs. if you change that here, that is a
breaking change for users of this crate, so that would need more
considerations imo.



_______________________________________________
yew-devel mailing list
yew-devel@lists.proxmox.com
https://lists.proxmox.com/cgi-bin/mailman/listinfo/yew-devel