mirror of
https://github.com/zadam/trilium.git
synced 2026-05-07 04:36:43 +02:00
chore(options/i18n): simplify first week of the year
This commit is contained in:
@@ -1412,11 +1412,10 @@
|
||||
"sunday": "Sunday",
|
||||
"first-week-of-the-year": "First week of the year",
|
||||
"first-week-contains-first-day": "First week contains first day of the year",
|
||||
"first-week-contains-first-thursday": "First week contains first Thursday of the year",
|
||||
"first-week-contains-first-thursday": "First week contains first Thursday (ISO 8601)",
|
||||
"first-week-has-minimum-days": "First week has minimum days",
|
||||
"min-days-in-first-week": "Minimum days in first week",
|
||||
"first-week-info": "First week contains first Thursday of the year is based on <a href=\"https://en.wikipedia.org/wiki/ISO_week_date#First_week\">ISO 8601</a> standard.",
|
||||
"first-week-warning": "Changing first week options may cause duplicate with existing Week Notes and the existing Week Notes will not be updated accordingly.",
|
||||
"first-week-warning": "Changing this may cause duplicates with existing Week Notes.",
|
||||
"formatting-locale": "Date & number format",
|
||||
"formatting-locale-auto": "Based on the application's language"
|
||||
},
|
||||
|
||||
@@ -6,10 +6,7 @@ import OptionsSection from "./components/OptionsSection";
|
||||
import { useTriliumOption, useTriliumOptionJson } from "../../react/hooks";
|
||||
import type { Locale } from "@triliumnext/commons";
|
||||
import { isElectron, restartDesktopApp } from "../../../services/utils";
|
||||
import FormRadioGroup from "../../react/FormRadioGroup";
|
||||
import FormText from "../../react/FormText";
|
||||
import RawHtml from "../../react/RawHtml";
|
||||
import Admonition from "../../react/Admonition";
|
||||
import Button from "../../react/Button";
|
||||
import CheckboxList from "./components/CheckboxList";
|
||||
import RelatedSettings from "./components/RelatedSettings";
|
||||
@@ -96,10 +93,13 @@ function DateSettings() {
|
||||
/>
|
||||
</OptionsRow>
|
||||
|
||||
<OptionsRow name="first-week-of-year" label={t("i18n.first-week-of-the-year")}>
|
||||
<FormRadioGroup
|
||||
<OptionsRow name="first-week-of-year" label={t("i18n.first-week-of-the-year")} description={t("i18n.first-week-warning")}>
|
||||
<FormSelect
|
||||
name="first-week-of-year"
|
||||
currentValue={firstWeekOfYear} onChange={setFirstWeekOfYear}
|
||||
currentValue={firstWeekOfYear}
|
||||
onChange={setFirstWeekOfYear}
|
||||
keyProperty="value"
|
||||
titleProperty="label"
|
||||
values={[
|
||||
{ value: "0", label: t("i18n.first-week-contains-first-day") },
|
||||
{ value: "1", label: t("i18n.first-week-contains-first-thursday") },
|
||||
@@ -117,14 +117,6 @@ function DateSettings() {
|
||||
(_, i) => ({ days: String(i + 1) }))} />
|
||||
</OptionsRow>}
|
||||
|
||||
<FormText>
|
||||
<RawHtml html={t("i18n.first-week-info")} />
|
||||
</FormText>
|
||||
|
||||
<Admonition type="warning">
|
||||
{t("i18n.first-week-warning")}
|
||||
</Admonition>
|
||||
|
||||
<OptionsRow name="restart" centered>
|
||||
<Button
|
||||
name="restart-app-button"
|
||||
|
||||
Reference in New Issue
Block a user