@seamly/web-ui 21.0.2-beta.4 → 21.0.2-beta.5
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.
- package/build/dist/lib/components.js +10 -4
- package/build/dist/lib/components.min.js +1 -1
- package/build/dist/lib/index.debug.js +3 -3
- package/build/dist/lib/index.debug.min.js +1 -1
- package/build/dist/lib/index.js +11 -5
- package/build/dist/lib/index.min.js +1 -1
- package/build/dist/lib/standalone.js +11 -5
- package/build/dist/lib/standalone.min.js +1 -1
- package/build/dist/lib/style-guide.js +12 -6
- package/build/dist/lib/style-guide.min.js +1 -1
- package/build/dist/lib/styles-default-implementation.js +1 -1
- package/build/dist/lib/styles.js +1 -1
- package/build/dist/lib/utils.js +11 -5
- package/build/dist/lib/utils.min.js +1 -1
- package/package.json +7 -6
- package/src/javascripts/domains/translations/components/options-dialog/translation-option.tsx +20 -19
- package/src/javascripts/domains/translations/components/options-dialog/translation-options.tsx +2 -0
- package/src/javascripts/style-guide/components/view.js +2 -2
- package/src/stylesheets/5-components/_translation-options.scss +23 -35
- package/src/stylesheets/6-default-implementation/_hover.scss +4 -0
package/build/dist/lib/index.js
CHANGED
|
@@ -7255,7 +7255,7 @@ _API_ready = new WeakMap(), _API_externalId = new WeakMap(), _API_layoutMode = n
|
|
|
7255
7255
|
return {
|
|
7256
7256
|
clientName: "@seamly/web-ui",
|
|
7257
7257
|
clientVariant: api_classPrivateFieldGet(this, _API_layoutMode, "f"),
|
|
7258
|
-
clientVersion: "21.0.
|
|
7258
|
+
clientVersion: "21.0.1",
|
|
7259
7259
|
currentUrl: window.location.toString(),
|
|
7260
7260
|
screenResolution: `${window.screen.width}x${window.screen.height}`,
|
|
7261
7261
|
timezone: getTimeZone(),
|
|
@@ -19960,9 +19960,15 @@ const OptionsButton = () => {
|
|
|
19960
19960
|
|
|
19961
19961
|
|
|
19962
19962
|
|
|
19963
|
-
const TranslationOption = ({ label, checked, description, onChange, id, }) =>
|
|
19964
|
-
|
|
19965
|
-
|
|
19963
|
+
const TranslationOption = ({ label, checked, description, onChange, id, }) => {
|
|
19964
|
+
const onKeyDown = (e) => {
|
|
19965
|
+
if (e.code === 'Space' || e.code === 'Enter') {
|
|
19966
|
+
e.preventDefault();
|
|
19967
|
+
onChange();
|
|
19968
|
+
}
|
|
19969
|
+
};
|
|
19970
|
+
return ((0,jsx_runtime_namespaceObject.jsxs)("li", Object.assign({ className: css_className('translation-options__item'), "aria-selected": checked, role: "option", tabIndex: 0, onClick: onChange, onKeyDown: onKeyDown, id: id }, { children: [(0,jsx_runtime_namespaceObject.jsx)(layout_icon, { alt: "", name: "check", size: "16" }), label, " ", description && (0,jsx_runtime_namespaceObject.jsxs)("span", { children: ["(", description, ")"] })] })));
|
|
19971
|
+
};
|
|
19966
19972
|
/* harmony default export */ const translation_option = (TranslationOption);
|
|
19967
19973
|
|
|
19968
19974
|
;// CONCATENATED MODULE: ./src/javascripts/domains/translations/components/options-dialog/translation-options.tsx
|
|
@@ -19999,7 +20005,7 @@ const TranslationOptions = ({ onChange, describedById, }) => {
|
|
|
19999
20005
|
});
|
|
20000
20006
|
});
|
|
20001
20007
|
}, [languages, defaultLocale]);
|
|
20002
|
-
return ((0,jsx_runtime_namespaceObject.jsx)("ul", Object.assign({ "aria-describedby": describedById, className: css_className('translation-options') }, { children: sortedLanguages.map((language, idx) => {
|
|
20008
|
+
return ((0,jsx_runtime_namespaceObject.jsx)("ul", Object.assign({ "aria-describedby": describedById, role: "listbox", tabIndex: -1, className: css_className('translation-options') }, { children: sortedLanguages.map((language, idx) => {
|
|
20003
20009
|
const isOriginal = idx === 0;
|
|
20004
20010
|
const checked = currentLocale === language.locale || (!currentLocale && isOriginal);
|
|
20005
20011
|
return ((0,jsx_runtime_namespaceObject.jsx)(translation_option, { id: language.locale, label: language.nativeName, checked: checked, description: isOriginal && t('translations.settings.original'), onChange: handleChange(language) }, language.locale));
|