@sveltia/ui 0.44.1 → 0.45.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -24,8 +24,24 @@ export const increaseListIndentation = (value) => {
24
24
  return value;
25
25
  }
26
26
 
27
- return value.replace(
28
- /^(\s+)(-|\+|\*|\d+\.)/gm,
29
- (_match, p1, p2) => `${' '.repeat(p1.length * 2)}${p2}`,
30
- );
27
+ let inCodeBlock = false;
28
+
29
+ return value
30
+ .split('\n')
31
+ .map((line) => {
32
+ if (/^(`{3,}|~{3,})/.test(line)) {
33
+ inCodeBlock = !inCodeBlock;
34
+ return line;
35
+ }
36
+
37
+ if (inCodeBlock) {
38
+ return line;
39
+ }
40
+
41
+ return line.replace(
42
+ /^(\s+)(-|\+|\*|\d+\.)/,
43
+ (_match, p1, p2) => `${' '.repeat(p1.length * 2)}${p2}`,
44
+ );
45
+ })
46
+ .join('\n');
31
47
  };
@@ -0,0 +1,113 @@
1
+ # Dialog action button labels
2
+ ok: OK
3
+ cancel: Cancel
4
+ close: Close
5
+
6
+ # Button to clear content, e.g. search input or calendar date
7
+ clear: Clear
8
+
9
+ # Text editor dialog buttons for link/image insertion
10
+ insert: Insert
11
+ update: Update
12
+ remove: Remove
13
+
14
+ # Combobox dropdown toggle button aria-labels
15
+ collapse: Collapse
16
+ expand: Expand
17
+
18
+ # Infobar/toast dismiss button label
19
+ dismiss: Dismiss
20
+
21
+ # Calendar component
22
+ calendar:
23
+ # View switcher group aria-labels and navigation button aria-labels
24
+ year: Year
25
+ previous_decade: Previous Decade
26
+ next_decade: Next Decade
27
+ month: Month
28
+ previous_month: Previous Month
29
+ next_month: Next Month
30
+ # “Today” button label in footer
31
+ today: Today
32
+
33
+ # Split button component
34
+ split_button:
35
+ # Wrapper aria-label, e.g. “Save Options” when primary button is “Save”
36
+ x_options: "{$name} Options"
37
+ # Dropdown toggle aria-label
38
+ more_options: More Options
39
+
40
+ # Combobox component
41
+ combobox:
42
+ # Placeholder when no option is selected
43
+ select_an_option: Select an option…
44
+ # Filter input aria-label
45
+ filter_options: Filter Options
46
+ # Empty state message when filter has no matches
47
+ no_matching_options: No matching options found
48
+
49
+ # Number input component
50
+ number_input:
51
+ # Spin button aria-labels for incrementing/decrementing the number value
52
+ increase: Increase
53
+ decrease: Decrease
54
+
55
+ # Password input component
56
+ password_input:
57
+ # Visibility toggle button aria-labels
58
+ show_password: Show Password
59
+ hide_password: Hide Password
60
+
61
+ # Secret input component (API keys, tokens, etc.)
62
+ secret_input:
63
+ # Visibility toggle button aria-labels
64
+ show_secret: Show Secret
65
+ hide_secret: Hide Secret
66
+
67
+ # Select tags component (multi-select)
68
+ select_tags:
69
+ # Listbox aria-label
70
+ selected_options: Selected Options
71
+ # Remove button aria-label, e.g. “Remove Option 1”
72
+ remove_x: "Remove {$name}"
73
+
74
+ # Text editor component
75
+ text_editor:
76
+ # Toolbar aria-labels
77
+ text_editor: Text Editor
78
+ code_editor: Code Editor
79
+ # Block style menu button and menu aria-labels
80
+ text_style_options: Text Style Options
81
+ show_text_style_options: Show Text Style Options
82
+ # Block style menu items
83
+ paragraph: Paragraph
84
+ heading_1: Heading 1
85
+ heading_2: Heading 2
86
+ heading_3: Heading 3
87
+ heading_4: Heading 4
88
+ heading_5: Heading 5
89
+ heading_6: Heading 6
90
+ bulleted_list: Bulleted List
91
+ numbered_list: Numbered List
92
+ blockquote: Block Quote
93
+ code_block: Code Block
94
+ # Inline style button aria-labels
95
+ bold: Bold
96
+ italic: Italic
97
+ strikethrough: Strikethrough
98
+ code: Code
99
+ link: Link
100
+ # Link dialog title
101
+ insert_link: Insert Link
102
+ update_link: Update Link
103
+ # Link dialog input field labels
104
+ text: Text
105
+ url: URL
106
+ # Markdown mode toggle button aria-label
107
+ edit_in_markdown: Edit in Markdown
108
+ # Error message when rich text conversion fails
109
+ converter_error: Unable to enable rich text mode. Please use the plain text editor instead.
110
+ # Language selector aria-label
111
+ language: Language
112
+ # Plain text mode option in language selector
113
+ plain_text: Plain Text
@@ -0,0 +1,113 @@
1
+ # Dialog action button labels
2
+ ok: OK
3
+ cancel: Cancel
4
+ close: Close
5
+
6
+ # Button to clear content, e.g. search input or calendar date
7
+ clear: Clear
8
+
9
+ # Text editor dialog buttons for link/image insertion
10
+ insert: Insert
11
+ update: Update
12
+ remove: Remove
13
+
14
+ # Combobox dropdown toggle button aria-labels
15
+ collapse: Collapse
16
+ expand: Expand
17
+
18
+ # Infobar/toast dismiss button label
19
+ dismiss: Dismiss
20
+
21
+ # Calendar component
22
+ calendar:
23
+ # View switcher group aria-labels and navigation button aria-labels
24
+ year: Year
25
+ previous_decade: Previous Decade
26
+ next_decade: Next Decade
27
+ month: Month
28
+ previous_month: Previous Month
29
+ next_month: Next Month
30
+ # “Today” button label in footer
31
+ today: Today
32
+
33
+ # Split button component
34
+ split_button:
35
+ # Wrapper aria-label, e.g. “Save Options” when primary button is “Save”
36
+ x_options: "{$name} Options"
37
+ # Dropdown toggle aria-label
38
+ more_options: More Options
39
+
40
+ # Combobox component
41
+ combobox:
42
+ # Placeholder when no option is selected
43
+ select_an_option: Select an option…
44
+ # Filter input aria-label
45
+ filter_options: Filter Options
46
+ # Empty state message when filter has no matches
47
+ no_matching_options: No matching options found
48
+
49
+ # Number input component
50
+ number_input:
51
+ # Spin button aria-labels for incrementing/decrementing the number value
52
+ increase: Increase
53
+ decrease: Decrease
54
+
55
+ # Password input component
56
+ password_input:
57
+ # Visibility toggle button aria-labels
58
+ show_password: Show Password
59
+ hide_password: Hide Password
60
+
61
+ # Secret input component (API keys, tokens, etc.)
62
+ secret_input:
63
+ # Visibility toggle button aria-labels
64
+ show_secret: Show Secret
65
+ hide_secret: Hide Secret
66
+
67
+ # Select tags component (multi-select)
68
+ select_tags:
69
+ # Listbox aria-label
70
+ selected_options: Selected Options
71
+ # Remove button aria-label, e.g. “Remove Option 1”
72
+ remove_x: "Remove {$name}"
73
+
74
+ # Text editor component
75
+ text_editor:
76
+ # Toolbar aria-labels
77
+ text_editor: Text Editor
78
+ code_editor: Code Editor
79
+ # Block style menu button and menu aria-labels
80
+ text_style_options: Text Style Options
81
+ show_text_style_options: Show Text Style Options
82
+ # Block style menu items
83
+ paragraph: Paragraph
84
+ heading_1: Heading 1
85
+ heading_2: Heading 2
86
+ heading_3: Heading 3
87
+ heading_4: Heading 4
88
+ heading_5: Heading 5
89
+ heading_6: Heading 6
90
+ bulleted_list: Bulleted List
91
+ numbered_list: Numbered List
92
+ blockquote: Block Quote
93
+ code_block: Code Block
94
+ # Inline style button aria-labels
95
+ bold: Bold
96
+ italic: Italic
97
+ strikethrough: Strikethrough
98
+ code: Code
99
+ link: Link
100
+ # Link dialog title
101
+ insert_link: Insert Link
102
+ update_link: Update Link
103
+ # Link dialog input field labels
104
+ text: Text
105
+ url: URL
106
+ # Markdown mode toggle button aria-label
107
+ edit_in_markdown: Edit in Markdown
108
+ # Error message when rich text conversion fails
109
+ converter_error: Unable to enable rich text mode. Please use the plain text editor instead.
110
+ # Language selector aria-label
111
+ language: Language
112
+ # Plain text mode option in language selector
113
+ plain_text: Plain Text
@@ -23,7 +23,7 @@ export const strings = Object.fromEntries(
23
23
  * @see https://github.com/sveltia/sveltia-i18n
24
24
  * @see https://vitejs.dev/guide/features.html#glob-import
25
25
  */
26
- export const initLocales = ({ fallbackLocale = 'en', initialLocale = 'en' } = {}) => {
26
+ export const initLocales = ({ fallbackLocale = 'en-US', initialLocale = 'en-US' } = {}) => {
27
27
  Object.entries(strings).forEach(([locale, resource]) => {
28
28
  // Add `_sui` suffix to avoid collision with app localization
29
29
  addMessages(locale, { _sui: resource });
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@sveltia/ui",
3
- "version": "0.44.1",
3
+ "version": "0.45.0",
4
4
  "description": "A collection of Svelte components and utilities for building user interfaces.",
5
5
  "repository": {
6
6
  "type": "git",
@@ -53,7 +53,7 @@
53
53
  "devDependencies": {
54
54
  "@rollup/plugin-yaml": "^5.0.0",
55
55
  "@sveltejs/adapter-auto": "^7.0.1",
56
- "@sveltejs/kit": "^2.69.3",
56
+ "@sveltejs/kit": "^2.70.1",
57
57
  "@sveltejs/package": "^2.5.8",
58
58
  "@sveltejs/vite-plugin-svelte": "^7.2.0",
59
59
  "@vitest/coverage-v8": "^4.1.10",
@@ -62,25 +62,25 @@
62
62
  "eslint-config-airbnb-extended": "^3.1.1",
63
63
  "eslint-config-prettier": "^10.1.8",
64
64
  "eslint-plugin-import": "^2.32.0",
65
- "eslint-plugin-jsdoc": "^63.0.13",
65
+ "eslint-plugin-jsdoc": "^63.2.0",
66
66
  "eslint-plugin-package-json": "^1.6.0",
67
- "eslint-plugin-svelte": "^3.20.0",
67
+ "eslint-plugin-svelte": "^3.22.0",
68
68
  "globals": "^17.7.0",
69
- "happy-dom": "^20.10.6",
70
- "oxlint": "^1.74.0",
71
- "postcss": "^8.5.19",
69
+ "happy-dom": "^20.11.1",
70
+ "oxlint": "^1.75.0",
71
+ "postcss": "^8.5.22",
72
72
  "postcss-html": "^1.8.1",
73
- "prettier": "^3.9.5",
73
+ "prettier": "^3.9.6",
74
74
  "prettier-plugin-svelte": "^4.1.1",
75
- "sass": "^1.101.0",
76
- "stylelint": "^17.14.0",
75
+ "sass": "^1.101.6",
76
+ "stylelint": "^17.14.1",
77
77
  "stylelint-config-recommended-scss": "^17.0.1",
78
78
  "stylelint-scss": "^7.2.0",
79
- "svelte": "^5.56.5",
79
+ "svelte": "^5.56.7",
80
80
  "svelte-check": "^4.7.3",
81
81
  "svelte-preprocess": "^6.0.5",
82
82
  "tslib": "^2.8.1",
83
- "vite": "^8.1.4",
83
+ "vite": "^8.1.5",
84
84
  "vitest": "^4.1.10"
85
85
  },
86
86
  "peerDependencies": {
File without changes