cetec-design-system 4.5.0-0 → 4.6.0-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.
package/dist/index.js CHANGED
@@ -15578,6 +15578,7 @@ const defaultLocaleLabels = {
15578
15578
  apply: "Apply",
15579
15579
  dismiss: "Dismiss",
15580
15580
  closeDialog: "Close dialog",
15581
+ closeDrawer: "Close drawer",
15581
15582
  removeItem: (item) => `Remove ${item}`,
15582
15583
  removeFilter: (filter) => `Remove filter: ${filter}`,
15583
15584
  switchToTheme: (nextTheme) => `Switch to ${nextTheme} theme`,
@@ -15591,6 +15592,12 @@ const defaultLocaleLabels = {
15591
15592
  optionCreated: (value) => `${value} created and selected.`,
15592
15593
  optionRemoved: (label2) => `${label2} removed.`,
15593
15594
  moreSelected: (count2) => `${count2} more selected`,
15595
+ copyCode: "Copy code",
15596
+ copied: "Copied",
15597
+ copyFailed: "Copy failed",
15598
+ showAllLines: (count2) => `Show all ${count2} lines`,
15599
+ showLess: "Show less",
15600
+ moreTabs: "More tabs",
15594
15601
  chooseDate: "Choose date",
15595
15602
  previousMonth: "Previous month",
15596
15603
  nextMonth: "Next month",
@@ -17693,13 +17700,14 @@ const scrollbarHeight = (element) => {
17693
17700
  );
17694
17701
  };
17695
17702
  const CodeBlock = (props) => {
17703
+ const { labels } = useLocale();
17696
17704
  const {
17697
17705
  code: codeProp,
17698
17706
  children,
17699
17707
  language,
17700
17708
  title,
17701
17709
  copyable = true,
17702
- copyLabel = "Copy code",
17710
+ copyLabel = labels.copyCode,
17703
17711
  maxLines,
17704
17712
  expanded: expandedProp,
17705
17713
  defaultExpanded = false,
@@ -17778,7 +17786,7 @@ const CodeBlock = (props) => {
17778
17786
  {
17779
17787
  ...dsPart("copy"),
17780
17788
  iconName: copied ? "check" : "copy",
17781
- altText: copied ? "Copied" : copyLabel,
17789
+ altText: copied ? labels.copied : copyLabel,
17782
17790
  variant: tone === "inverse" ? "primary" : "ghost",
17783
17791
  size: "sm",
17784
17792
  onClick: () => {
@@ -17861,11 +17869,11 @@ const CodeBlock = (props) => {
17861
17869
  "aria-hidden": "true"
17862
17870
  }
17863
17871
  ),
17864
- expanded ? "Show less" : `Show all ${lineCount} lines`
17872
+ expanded ? labels.showLess : labels.showAllLines(lineCount)
17865
17873
  ]
17866
17874
  }
17867
17875
  ),
17868
- /* @__PURE__ */ jsx(Box, { as: "span", role: "status", "aria-live": "polite", srOnly: true, children: copied ? "Copied" : failed ? "Copy failed" : "" })
17876
+ /* @__PURE__ */ jsx(Box, { as: "span", role: "status", "aria-live": "polite", srOnly: true, children: copied ? labels.copied : failed ? labels.copyFailed : "" })
17869
17877
  ]
17870
17878
  }
17871
17879
  );
@@ -22653,6 +22661,7 @@ const DrawerHeader = (props) => {
22653
22661
  const classes = drawer();
22654
22662
  const { onClose } = useDrawerContext();
22655
22663
  const isSm = useMediaQuery("sm");
22664
+ const { labels } = useLocale();
22656
22665
  return /* @__PURE__ */ jsx(Box, { className: cx(classes.header, className), ...otherProps, children: children ? children : /* @__PURE__ */ jsxs(Fragment, { children: [
22657
22666
  title && /* @__PURE__ */ jsx(
22658
22667
  Heading,
@@ -22670,8 +22679,8 @@ const DrawerHeader = (props) => {
22670
22679
  variant: "ghost",
22671
22680
  size: isSm ? "md" : "lg",
22672
22681
  onClick: onClose,
22673
- altText: "Close drawer",
22674
- "aria-label": "Close drawer",
22682
+ altText: labels.closeDrawer,
22683
+ "aria-label": labels.closeDrawer,
22675
22684
  className: classes.closeButton,
22676
22685
  iconName: "x"
22677
22686
  }
@@ -24165,6 +24174,7 @@ const TabsOverflowMenu = ({
24165
24174
  selectedValue
24166
24175
  }) => {
24167
24176
  const [isOpen, setIsOpen] = useState(false);
24177
+ const { labels } = useLocale();
24168
24178
  return /* @__PURE__ */ jsx(
24169
24179
  Menu,
24170
24180
  {
@@ -24178,7 +24188,7 @@ const TabsOverflowMenu = ({
24178
24188
  variant: "ghost",
24179
24189
  size: "md",
24180
24190
  iconName: isOpen ? "caret-up" : "caret-down",
24181
- altText: "More tabs",
24191
+ altText: labels.moreTabs,
24182
24192
  "aria-haspopup": "menu"
24183
24193
  }
24184
24194
  ),
@@ -24206,6 +24216,7 @@ const TabsOverflowMenu = ({
24206
24216
  );
24207
24217
  };
24208
24218
  const Tabs = (props) => {
24219
+ const { labels } = useLocale();
24209
24220
  const {
24210
24221
  children,
24211
24222
  value,
@@ -24319,7 +24330,7 @@ const Tabs = (props) => {
24319
24330
  variant: "ghost",
24320
24331
  size: "md",
24321
24332
  iconName: "caret-down",
24322
- altText: "More tabs",
24333
+ altText: labels.moreTabs,
24323
24334
  disabled: true,
24324
24335
  tabIndex: -1
24325
24336
  }