@dynatrace/strato-components 0.84.21 → 0.84.42

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.
Files changed (230) hide show
  1. package/core/components/app-root/AppRoot.d.ts +9 -4
  2. package/core/components/app-root/AppRoot.js +6 -2
  3. package/core/contexts/FocusContext.d.ts +1 -1
  4. package/core/hooks/useCurrentTheme.d.ts +4 -1
  5. package/core/hooks/useFontsUpdated.d.ts +9 -0
  6. package/core/hooks/useFontsUpdated.js +51 -0
  7. package/core/hooks/useMergeRefs.d.ts +7 -0
  8. package/core/hooks/useMergeRefs.js +34 -0
  9. package/core/index.d.ts +5 -0
  10. package/core/styles/focusRing.css +88 -0
  11. package/core/styles/focusRing.sty.d.ts +96 -0
  12. package/core/styles/focusRing.sty.js +27 -0
  13. package/core/styles/useFocusRing.d.ts +49 -0
  14. package/core/styles/useFocusRing.js +83 -0
  15. package/core/types/a11y-props.d.ts +19 -0
  16. package/core/types/a11y-props.js +15 -0
  17. package/core/types/data-props.d.ts +1 -0
  18. package/core/types/dom.d.ts +19 -0
  19. package/core/types/dom.js +15 -0
  20. package/core/types/focusable-element.d.ts +5 -0
  21. package/core/types/focusable-element.js +15 -0
  22. package/core/types/heading.d.ts +9 -0
  23. package/core/types/heading.js +15 -0
  24. package/core/types/masking-props.d.ts +9 -0
  25. package/core/types/masking-props.js +15 -0
  26. package/core/types/polymorph.d.ts +25 -0
  27. package/core/types/polymorph.js +15 -0
  28. package/core/types/styling-props.d.ts +3 -2
  29. package/core/types/with-children.d.ts +4 -1
  30. package/core/utils/colorUtils.css +80 -0
  31. package/core/utils/colorUtils.sty.d.ts +48 -0
  32. package/core/utils/colorUtils.sty.js +27 -0
  33. package/esm/core/components/app-root/AppRoot.js +6 -2
  34. package/esm/core/components/app-root/AppRoot.js.map +2 -2
  35. package/esm/core/contexts/FocusContext.js.map +1 -1
  36. package/esm/core/hooks/useCurrentTheme.js.map +2 -2
  37. package/esm/core/hooks/useFontsUpdated.js +33 -0
  38. package/esm/core/hooks/useFontsUpdated.js.map +7 -0
  39. package/esm/core/hooks/useMergeRefs.js +16 -0
  40. package/esm/core/hooks/useMergeRefs.js.map +7 -0
  41. package/esm/core/index.js.map +2 -2
  42. package/esm/core/styles/focusRing.css +88 -0
  43. package/esm/core/styles/focusRing.sty.js +9 -0
  44. package/esm/core/styles/focusRing.sty.js.map +7 -0
  45. package/esm/core/styles/useFocusRing.js +69 -0
  46. package/esm/core/styles/useFocusRing.js.map +7 -0
  47. package/esm/core/types/a11y-props.js +1 -0
  48. package/esm/core/types/a11y-props.js.map +7 -0
  49. package/esm/core/types/dom.js +1 -0
  50. package/esm/core/types/dom.js.map +7 -0
  51. package/esm/core/types/focusable-element.js +1 -0
  52. package/esm/core/types/focusable-element.js.map +7 -0
  53. package/esm/core/types/heading.js +1 -0
  54. package/esm/core/types/heading.js.map +7 -0
  55. package/esm/core/types/masking-props.js +1 -0
  56. package/esm/core/types/masking-props.js.map +7 -0
  57. package/esm/core/types/polymorph.js +1 -0
  58. package/esm/core/types/polymorph.js.map +7 -0
  59. package/esm/core/utils/colorUtils.css +80 -0
  60. package/esm/core/utils/colorUtils.sty.js +9 -0
  61. package/esm/core/utils/colorUtils.sty.js.map +7 -0
  62. package/esm/index.js +2 -0
  63. package/esm/index.js.map +2 -2
  64. package/esm/layouts/Divider/Divider.css +23 -0
  65. package/esm/layouts/Divider/Divider.js +39 -0
  66. package/esm/layouts/Divider/Divider.js.map +7 -0
  67. package/esm/layouts/Divider/Divider.sty.js +8 -0
  68. package/esm/layouts/Divider/Divider.sty.js.map +7 -0
  69. package/esm/layouts/index.js +5 -0
  70. package/esm/layouts/index.js.map +7 -0
  71. package/esm/styles/textStyle.css +64 -0
  72. package/esm/styles/textStyle.sty.js +7 -0
  73. package/esm/styles/textStyle.sty.js.map +7 -0
  74. package/esm/typography/BlockQuote/Blockquote.css +17 -0
  75. package/esm/typography/BlockQuote/Blockquote.js +34 -0
  76. package/esm/typography/BlockQuote/Blockquote.js.map +7 -0
  77. package/esm/typography/BlockQuote/Blockquote.sty.js +6 -0
  78. package/esm/typography/BlockQuote/Blockquote.sty.js.map +7 -0
  79. package/esm/typography/Code/Code.css +16 -0
  80. package/esm/typography/Code/Code.js +34 -0
  81. package/esm/typography/Code/Code.js.map +7 -0
  82. package/esm/typography/Code/Code.sty.js +6 -0
  83. package/esm/typography/Code/Code.sty.js.map +7 -0
  84. package/esm/typography/Emphasis/Emphasis.css +4 -0
  85. package/esm/typography/Emphasis/Emphasis.js +34 -0
  86. package/esm/typography/Emphasis/Emphasis.js.map +7 -0
  87. package/esm/typography/Emphasis/Emphasis.sty.js +6 -0
  88. package/esm/typography/Emphasis/Emphasis.sty.js.map +7 -0
  89. package/esm/typography/ExternalLink/ExternalLink.css +28 -0
  90. package/esm/typography/ExternalLink/ExternalLink.js +56 -0
  91. package/esm/typography/ExternalLink/ExternalLink.js.map +7 -0
  92. package/esm/typography/ExternalLink/ExternalLink.sty.js +6 -0
  93. package/esm/typography/ExternalLink/ExternalLink.sty.js.map +7 -0
  94. package/esm/typography/Heading/Heading.css +54 -0
  95. package/esm/typography/Heading/Heading.js +36 -0
  96. package/esm/typography/Heading/Heading.js.map +7 -0
  97. package/esm/typography/Heading/Heading.sty.js +7 -0
  98. package/esm/typography/Heading/Heading.sty.js.map +7 -0
  99. package/esm/typography/Highlight/Highlight.css +4 -0
  100. package/esm/typography/Highlight/Highlight.js +111 -0
  101. package/esm/typography/Highlight/Highlight.js.map +7 -0
  102. package/esm/typography/Highlight/Highlight.sty.js +6 -0
  103. package/esm/typography/Highlight/Highlight.sty.js.map +7 -0
  104. package/esm/typography/Link/Link.css +15 -0
  105. package/esm/typography/Link/Link.js +49 -0
  106. package/esm/typography/Link/Link.js.map +7 -0
  107. package/esm/typography/Link/Link.sty.js +6 -0
  108. package/esm/typography/Link/Link.sty.js.map +7 -0
  109. package/esm/typography/List/List.css +16 -0
  110. package/esm/typography/List/List.js +81 -0
  111. package/esm/typography/List/List.js.map +7 -0
  112. package/esm/typography/List/List.sty.js +8 -0
  113. package/esm/typography/List/List.sty.js.map +7 -0
  114. package/esm/typography/Paragraph/Paragraph.css +19 -0
  115. package/esm/typography/Paragraph/Paragraph.js +49 -0
  116. package/esm/typography/Paragraph/Paragraph.js.map +7 -0
  117. package/esm/typography/Paragraph/Paragraph.sty.js +7 -0
  118. package/esm/typography/Paragraph/Paragraph.sty.js.map +7 -0
  119. package/esm/typography/Strikethrough/Strikethrough.css +5 -0
  120. package/esm/typography/Strikethrough/Strikethrough.js +32 -0
  121. package/esm/typography/Strikethrough/Strikethrough.js.map +7 -0
  122. package/esm/typography/Strikethrough/Strikethrough.sty.js +6 -0
  123. package/esm/typography/Strikethrough/Strikethrough.sty.js.map +7 -0
  124. package/esm/typography/Strong/Strong.css +4 -0
  125. package/esm/typography/Strong/Strong.js +34 -0
  126. package/esm/typography/Strong/Strong.js.map +7 -0
  127. package/esm/typography/Strong/Strong.sty.js +6 -0
  128. package/esm/typography/Strong/Strong.sty.js.map +7 -0
  129. package/esm/typography/Text/Text.css +18 -0
  130. package/esm/typography/Text/Text.js +43 -0
  131. package/esm/typography/Text/Text.js.map +7 -0
  132. package/esm/typography/Text/Text.sty.js +7 -0
  133. package/esm/typography/Text/Text.sty.js.map +7 -0
  134. package/esm/typography/TextEllipsis/TextEllipsis.css +22 -0
  135. package/esm/typography/TextEllipsis/TextEllipsis.js +143 -0
  136. package/esm/typography/TextEllipsis/TextEllipsis.js.map +7 -0
  137. package/esm/typography/TextEllipsis/TextEllipsis.sty.js +7 -0
  138. package/esm/typography/TextEllipsis/TextEllipsis.sty.js.map +7 -0
  139. package/esm/typography/index.js +43 -0
  140. package/esm/typography/index.js.map +7 -0
  141. package/esm/typography/utils.js +101 -0
  142. package/esm/typography/utils.js.map +7 -0
  143. package/index.d.ts +2 -0
  144. package/index.js +2 -0
  145. package/lang/en.json +6 -0
  146. package/lang/uncompiled/en.json +6 -1
  147. package/layouts/Divider/Divider.css +23 -0
  148. package/layouts/Divider/Divider.d.ts +39 -0
  149. package/layouts/Divider/Divider.js +67 -0
  150. package/layouts/Divider/Divider.sty.d.ts +16 -0
  151. package/layouts/Divider/Divider.sty.js +26 -0
  152. package/layouts/index.d.ts +2 -0
  153. package/layouts/index.js +23 -0
  154. package/package.json +17 -2
  155. package/styles/textStyle.css +64 -0
  156. package/styles/textStyle.sty.d.ts +12 -0
  157. package/styles/textStyle.sty.js +25 -0
  158. package/testing/custom-render.d.ts +1 -1
  159. package/testing/mocks/resize-observer-mock.d.ts +1 -1
  160. package/testing/mocks/text-ellipsis-mock.d.ts +1 -1
  161. package/testing/mocks/text-ellipsis-mock.js +8 -3
  162. package/typography/BlockQuote/Blockquote.css +17 -0
  163. package/typography/BlockQuote/Blockquote.d.ts +19 -0
  164. package/typography/BlockQuote/Blockquote.js +62 -0
  165. package/typography/BlockQuote/Blockquote.sty.d.ts +1 -0
  166. package/typography/BlockQuote/Blockquote.sty.js +24 -0
  167. package/typography/Code/Code.css +16 -0
  168. package/typography/Code/Code.d.ts +17 -0
  169. package/typography/Code/Code.js +62 -0
  170. package/typography/Code/Code.sty.d.ts +1 -0
  171. package/typography/Code/Code.sty.js +24 -0
  172. package/typography/Emphasis/Emphasis.css +4 -0
  173. package/typography/Emphasis/Emphasis.d.ts +14 -0
  174. package/typography/Emphasis/Emphasis.js +62 -0
  175. package/typography/Emphasis/Emphasis.sty.d.ts +1 -0
  176. package/typography/Emphasis/Emphasis.sty.js +24 -0
  177. package/typography/ExternalLink/ExternalLink.css +28 -0
  178. package/typography/ExternalLink/ExternalLink.d.ts +21 -0
  179. package/typography/ExternalLink/ExternalLink.js +82 -0
  180. package/typography/ExternalLink/ExternalLink.sty.d.ts +1 -0
  181. package/typography/ExternalLink/ExternalLink.sty.js +24 -0
  182. package/typography/Heading/Heading.css +54 -0
  183. package/typography/Heading/Heading.d.ts +24 -0
  184. package/typography/Heading/Heading.js +64 -0
  185. package/typography/Heading/Heading.sty.d.ts +52 -0
  186. package/typography/Heading/Heading.sty.js +25 -0
  187. package/typography/Highlight/Highlight.css +4 -0
  188. package/typography/Highlight/Highlight.d.ts +27 -0
  189. package/typography/Highlight/Highlight.js +139 -0
  190. package/typography/Highlight/Highlight.sty.d.ts +1 -0
  191. package/typography/Highlight/Highlight.sty.js +24 -0
  192. package/typography/Link/Link.css +15 -0
  193. package/typography/Link/Link.d.ts +17 -0
  194. package/typography/Link/Link.js +75 -0
  195. package/typography/Link/Link.sty.d.ts +1 -0
  196. package/typography/Link/Link.sty.js +24 -0
  197. package/typography/List/List.css +16 -0
  198. package/typography/List/List.d.ts +39 -0
  199. package/typography/List/List.js +109 -0
  200. package/typography/List/List.sty.d.ts +2 -0
  201. package/typography/List/List.sty.js +26 -0
  202. package/typography/Paragraph/Paragraph.css +19 -0
  203. package/typography/Paragraph/Paragraph.d.ts +19 -0
  204. package/typography/Paragraph/Paragraph.js +77 -0
  205. package/typography/Paragraph/Paragraph.sty.d.ts +16 -0
  206. package/typography/Paragraph/Paragraph.sty.js +25 -0
  207. package/typography/Strikethrough/Strikethrough.css +5 -0
  208. package/typography/Strikethrough/Strikethrough.d.ts +15 -0
  209. package/typography/Strikethrough/Strikethrough.js +60 -0
  210. package/typography/Strikethrough/Strikethrough.sty.d.ts +1 -0
  211. package/typography/Strikethrough/Strikethrough.sty.js +24 -0
  212. package/typography/Strong/Strong.css +4 -0
  213. package/typography/Strong/Strong.d.ts +14 -0
  214. package/typography/Strong/Strong.js +62 -0
  215. package/typography/Strong/Strong.sty.d.ts +1 -0
  216. package/typography/Strong/Strong.sty.js +24 -0
  217. package/typography/Text/Text.css +18 -0
  218. package/typography/Text/Text.d.ts +26 -0
  219. package/typography/Text/Text.js +71 -0
  220. package/typography/Text/Text.sty.d.ts +16 -0
  221. package/typography/Text/Text.sty.js +25 -0
  222. package/typography/TextEllipsis/TextEllipsis.css +22 -0
  223. package/typography/TextEllipsis/TextEllipsis.d.ts +32 -0
  224. package/typography/TextEllipsis/TextEllipsis.js +167 -0
  225. package/typography/TextEllipsis/TextEllipsis.sty.d.ts +15 -0
  226. package/typography/TextEllipsis/TextEllipsis.sty.js +25 -0
  227. package/typography/index.d.ts +28 -0
  228. package/typography/index.js +54 -0
  229. package/typography/utils.d.ts +52 -0
  230. package/typography/utils.js +119 -0
@@ -0,0 +1,15 @@
1
+ var __defProp = Object.defineProperty;
2
+ var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
3
+ var __getOwnPropNames = Object.getOwnPropertyNames;
4
+ var __hasOwnProp = Object.prototype.hasOwnProperty;
5
+ var __copyProps = (to, from, except, desc) => {
6
+ if (from && typeof from === "object" || typeof from === "function") {
7
+ for (let key of __getOwnPropNames(from))
8
+ if (!__hasOwnProp.call(to, key) && key !== except)
9
+ __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
10
+ }
11
+ return to;
12
+ };
13
+ var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
14
+ var heading_exports = {};
15
+ module.exports = __toCommonJS(heading_exports);
@@ -0,0 +1,9 @@
1
+ /**
2
+ * @public
3
+ * Props defining the masking of data in Session Replay. They are applied to the component's root node. */
4
+ export interface MaskingProps {
5
+ /** Determines whether masking is enabled and the data is replaced with asterisks. */
6
+ 'data-dtrum-mask'?: boolean;
7
+ /** Determines whether masking is disabled and the data is shown. */
8
+ 'data-dtrum-allow'?: boolean;
9
+ }
@@ -0,0 +1,15 @@
1
+ var __defProp = Object.defineProperty;
2
+ var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
3
+ var __getOwnPropNames = Object.getOwnPropertyNames;
4
+ var __hasOwnProp = Object.prototype.hasOwnProperty;
5
+ var __copyProps = (to, from, except, desc) => {
6
+ if (from && typeof from === "object" || typeof from === "function") {
7
+ for (let key of __getOwnPropNames(from))
8
+ if (!__hasOwnProp.call(to, key) && key !== except)
9
+ __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
10
+ }
11
+ return to;
12
+ };
13
+ var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
14
+ var masking_props_exports = {};
15
+ module.exports = __toCommonJS(masking_props_exports);
@@ -0,0 +1,25 @@
1
+ import { ComponentProps, ElementType } from 'react';
2
+ /**
3
+ * @public
4
+ * Props type to use with your own to add the as polymorphing prop */
5
+ export type PolymorphOwnProps<E extends ElementType = ElementType> = {
6
+ /**
7
+ * The element type / component used to render
8
+ * e.g. when `a` is used an anchor tag is created and the component
9
+ * accepts all props a native anchor also accepts, e.g. a `href` tag.
10
+ * Custom components with their own props are also supported, e.g. a `Link`
11
+ * from a router.
12
+ */
13
+ as?: E;
14
+ };
15
+ /**
16
+ * @public
17
+ * Combine the props that come from the underlying ElementType and from your own types and omit naming duplicates */
18
+ export type PolymorphProps<E extends ElementType> = PolymorphOwnProps<E> & Omit<ComponentProps<E>, keyof PolymorphOwnProps>;
19
+ /**
20
+ * @public
21
+ * Uniontype for the elementtypes polymorph props and your own props P */
22
+ export type PolymorphicComponentProps<E extends ElementType, P> = P & PolymorphProps<E>;
23
+ declare module 'react' {
24
+ function forwardRef<T, P = unknown>(render: (props: P, ref: React.Ref<T>) => React.ReactElement | null): (props: P & React.RefAttributes<T>) => React.ReactElement | null;
25
+ }
@@ -0,0 +1,15 @@
1
+ var __defProp = Object.defineProperty;
2
+ var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
3
+ var __getOwnPropNames = Object.getOwnPropertyNames;
4
+ var __hasOwnProp = Object.prototype.hasOwnProperty;
5
+ var __copyProps = (to, from, except, desc) => {
6
+ if (from && typeof from === "object" || typeof from === "function") {
7
+ for (let key of __getOwnPropNames(from))
8
+ if (!__hasOwnProp.call(to, key) && key !== except)
9
+ __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
10
+ }
11
+ return to;
12
+ };
13
+ var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
14
+ var polymorph_exports = {};
15
+ module.exports = __toCommonJS(polymorph_exports);
@@ -1,5 +1,6 @@
1
- import React from 'react';
1
+ import type { CSSProperties } from 'react';
2
2
  /**
3
+ * @public
3
4
  * Collection of component styling props including `style` and `className` types.
4
5
  */
5
6
  export interface StylingProps {
@@ -14,5 +15,5 @@ export interface StylingProps {
14
15
  *
15
16
  * Be aware that overriding certain styles may result in unexpected behavior!
16
17
  */
17
- style?: React.CSSProperties;
18
+ style?: CSSProperties;
18
19
  }
@@ -1,5 +1,8 @@
1
1
  import type { ReactNode } from 'react';
2
- /** Helper type to add children to props */
2
+ /**
3
+ * @public
4
+ * Helper type to add children to props
5
+ */
3
6
  export interface WithChildren {
4
7
  /** Children provided to the component. */
5
8
  children?: ReactNode;
@@ -0,0 +1,80 @@
1
+ .colorUtils_colorUtilsCSS_color_critical__k096v44 {
2
+ --vars_text__k096v40: var(--dt-colors-text-critical-default, #b80031);
3
+ --vars_icon__k096v41: var(--dt-colors-icon-critical-default, #b80031);
4
+ --vars_borderColor__k096v42: var(--dt-colors-border-critical-default, #f1cdcf);
5
+ }
6
+ .colorUtils_colorUtilsCSS_color_neutral__k096v45 {
7
+ --vars_text__k096v40: var(--dt-colors-text-neutral-default, #2b2a58);
8
+ --vars_icon__k096v41: var(--dt-colors-icon-neutral-default, #2b2a58);
9
+ --vars_borderColor__k096v42: var(--dt-colors-border-neutral-default, #d2d3e1);
10
+ }
11
+ .colorUtils_colorUtilsCSS_color_primary__k096v46 {
12
+ --vars_text__k096v40: var(--dt-colors-text-primary-default, #454cc9);
13
+ --vars_icon__k096v41: var(--dt-colors-icon-primary-default, #454cc9);
14
+ --vars_borderColor__k096v42: var(--dt-colors-border-primary-default, #ccd3f3);
15
+ }
16
+ .colorUtils_colorUtilsCSS_color_success__k096v47 {
17
+ --vars_text__k096v40: var(--dt-colors-text-success-default, #2c6360);
18
+ --vars_icon__k096v41: var(--dt-colors-icon-success-default, #2c6360);
19
+ --vars_borderColor__k096v42: var(--dt-colors-border-success-default, #cad6d7);
20
+ }
21
+ .colorUtils_colorUtilsCSS_color_warning__k096v48 {
22
+ --vars_text__k096v40: var(--dt-colors-text-warning-default, #805100);
23
+ --vars_icon__k096v41: var(--dt-colors-icon-warning-default, #805100);
24
+ --vars_borderColor__k096v42: var(--dt-colors-border-warning-default, #f4e5d5);
25
+ }
26
+ .colorUtils_colorUtilsCSS_color_onAccent__k096v49 {
27
+ --vars_text__k096v40: var(--dt-colors-text-neutral-on-accent-default, #f3f3f6);
28
+ --vars_icon__k096v41: var(--dt-colors-icon-neutral-on-accent-default, #f3f3f6);
29
+ --vars_borderColor__k096v42: var(--dt-colors-border-neutral-on-accent-default, #f3f3f6);
30
+ }
31
+ .colorUtils_colorUtilsCSS_compound_0__k096v4e {
32
+ --vars_text__k096v40: var(--dt-colors-text-primary-on-accent-default, #f4f4fb);
33
+ --vars_icon__k096v41: var(--dt-colors-icon-primary-on-accent-default, #f4f4fb);
34
+ --vars_borderColor__k096v42: var(--dt-colors-border-primary-accent, #454cc9);
35
+ }
36
+ .colorUtils_colorUtilsCSS_compound_1__k096v4f {
37
+ --vars_text__k096v40: var(--dt-colors-text-success-on-accent-default, #f1f4f4);
38
+ --vars_icon__k096v41: var(--dt-colors-icon-success-on-accent-default, #f1f4f4);
39
+ --vars_borderColor__k096v42: var(--dt-colors-border-success-accent, #2c6360);
40
+ }
41
+ .colorUtils_colorUtilsCSS_compound_2__k096v4g {
42
+ --vars_text__k096v40: var(--dt-colors-text-warning-on-accent-default, #272025);
43
+ --vars_icon__k096v41: var(--dt-colors-icon-warning-on-accent-default, #272025);
44
+ --vars_borderColor__k096v42: var(--dt-colors-border-warning-accent, #805100);
45
+ }
46
+ .colorUtils_colorUtilsCSS_compound_3__k096v4h {
47
+ --vars_text__k096v40: var(--dt-colors-text-critical-on-accent-default, #f9f1f3);
48
+ --vars_icon__k096v41: var(--dt-colors-icon-critical-on-accent-default, #f9f1f3);
49
+ --vars_borderColor__k096v42: var(--dt-colors-border-critical-accent, #b80031);
50
+ }
51
+ .colorUtils_colorUtilsCSS_compound_4__k096v4i {
52
+ --vars_text__k096v40: var(--dt-colors-text-neutral-on-accent-default, #f3f3f6);
53
+ --vars_icon__k096v41: var(--dt-colors-icon-neutral-on-accent-default, #f3f3f6);
54
+ --vars_borderColor__k096v42: var(--dt-colors-border-neutral-accent, #545587);
55
+ }
56
+ .colorUtils_colorUtilsCSS_compound_5__k096v4j {
57
+ --vars_text__k096v40: var(--dt-colors-text-primary-disabled, #54558780);
58
+ --vars_icon__k096v41: var(--dt-colors-icon-primary-disabled, #54558780);
59
+ --vars_borderColor__k096v42: var(--dt-colors-border-primary-disabled, #d2d3e180);
60
+ }
61
+ .colorUtils_colorUtilsCSS_compound_6__k096v4k {
62
+ --vars_text__k096v40: var(--dt-colors-text-success-disabled, #54558780);
63
+ --vars_icon__k096v41: var(--dt-colors-icon-success-disabled, #54558780);
64
+ --vars_borderColor__k096v42: var(--dt-colors-border-success-disabled, #d2d3e180);
65
+ }
66
+ .colorUtils_colorUtilsCSS_compound_7__k096v4l {
67
+ --vars_text__k096v40: var(--dt-colors-text-warning-disabled, #54558780);
68
+ --vars_icon__k096v41: var(--dt-colors-icon-warning-disabled, #54558780);
69
+ --vars_borderColor__k096v42: var(--dt-colors-border-warning-disabled, #d2d3e180);
70
+ }
71
+ .colorUtils_colorUtilsCSS_compound_8__k096v4m {
72
+ --vars_text__k096v40: var(--dt-colors-text-critical-disabled, #54558780);
73
+ --vars_icon__k096v41: var(--dt-colors-icon-critical-disabled, #54558780);
74
+ --vars_borderColor__k096v42: var(--dt-colors-border-critical-disabled, #d2d3e180);
75
+ }
76
+ .colorUtils_colorUtilsCSS_compound_9__k096v4n {
77
+ --vars_text__k096v40: var(--dt-colors-text-neutral-disabled, #54558780);
78
+ --vars_icon__k096v41: var(--dt-colors-icon-neutral-disabled, #54558780);
79
+ --vars_borderColor__k096v42: var(--dt-colors-border-neutral-disabled, #d2d3e180);
80
+ }
@@ -0,0 +1,48 @@
1
+ declare const vars: {
2
+ text: `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
3
+ icon: `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
4
+ borderColor: `var(--${string})` | `var(--${string}, ${string})` | `var(--${string}, ${number})`;
5
+ };
6
+ export declare const colorUtilsCSS: import("@vanilla-extract/recipes").RuntimeFn<{
7
+ color: {
8
+ critical: {
9
+ vars: {
10
+ [x: string]: string;
11
+ };
12
+ };
13
+ neutral: {
14
+ vars: {
15
+ [x: string]: string;
16
+ };
17
+ };
18
+ primary: {
19
+ vars: {
20
+ [x: string]: string;
21
+ };
22
+ };
23
+ success: {
24
+ vars: {
25
+ [x: string]: string;
26
+ };
27
+ };
28
+ warning: {
29
+ vars: {
30
+ [x: string]: string;
31
+ };
32
+ };
33
+ onAccent: {
34
+ vars: {
35
+ [x: string]: string;
36
+ };
37
+ };
38
+ };
39
+ variant: {
40
+ default: {};
41
+ accent: {};
42
+ };
43
+ disabled: {
44
+ true: {};
45
+ false: {};
46
+ };
47
+ }>;
48
+ export { vars as colorUtilsVars };
@@ -0,0 +1,27 @@
1
+ var __defProp = Object.defineProperty;
2
+ var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
3
+ var __getOwnPropNames = Object.getOwnPropertyNames;
4
+ var __hasOwnProp = Object.prototype.hasOwnProperty;
5
+ var __export = (target, all) => {
6
+ for (var name in all)
7
+ __defProp(target, name, { get: all[name], enumerable: true });
8
+ };
9
+ var __copyProps = (to, from, except, desc) => {
10
+ if (from && typeof from === "object" || typeof from === "function") {
11
+ for (let key of __getOwnPropNames(from))
12
+ if (!__hasOwnProp.call(to, key) && key !== except)
13
+ __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
14
+ }
15
+ return to;
16
+ };
17
+ var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
18
+ var colorUtils_css_exports = {};
19
+ __export(colorUtils_css_exports, {
20
+ colorUtilsCSS: () => colorUtilsCSS,
21
+ colorUtilsVars: () => colorUtilsVars
22
+ });
23
+ module.exports = __toCommonJS(colorUtils_css_exports);
24
+ var import_colorUtils_css_ts_vanilla = require("./colorUtils.css");
25
+ var import_createRuntimeFn = require("@vanilla-extract/recipes/createRuntimeFn");
26
+ var colorUtilsCSS = (0, import_createRuntimeFn.createRuntimeFn)({ defaultClassName: "colorUtils__k096v43", variantClassNames: { color: { critical: "colorUtils_colorUtilsCSS_color_critical__k096v44", neutral: "colorUtils_colorUtilsCSS_color_neutral__k096v45", primary: "colorUtils_colorUtilsCSS_color_primary__k096v46", success: "colorUtils_colorUtilsCSS_color_success__k096v47", warning: "colorUtils_colorUtilsCSS_color_warning__k096v48", onAccent: "colorUtils_colorUtilsCSS_color_onAccent__k096v49" }, variant: { "default": "colorUtils_colorUtilsCSS_variant_default__k096v4a", accent: "colorUtils_colorUtilsCSS_variant_accent__k096v4b" }, disabled: { true: "colorUtils_colorUtilsCSS_disabled_true__k096v4c", false: "colorUtils_colorUtilsCSS_disabled_false__k096v4d" } }, defaultVariants: {}, compoundVariants: [[{ color: "primary", variant: "accent" }, "colorUtils_colorUtilsCSS_compound_0__k096v4e"], [{ color: "success", variant: "accent" }, "colorUtils_colorUtilsCSS_compound_1__k096v4f"], [{ color: "warning", variant: "accent" }, "colorUtils_colorUtilsCSS_compound_2__k096v4g"], [{ color: "critical", variant: "accent" }, "colorUtils_colorUtilsCSS_compound_3__k096v4h"], [{ color: "neutral", variant: "accent" }, "colorUtils_colorUtilsCSS_compound_4__k096v4i"], [{ color: "primary", disabled: true }, "colorUtils_colorUtilsCSS_compound_5__k096v4j"], [{ color: "success", disabled: true }, "colorUtils_colorUtilsCSS_compound_6__k096v4k"], [{ color: "warning", disabled: true }, "colorUtils_colorUtilsCSS_compound_7__k096v4l"], [{ color: "critical", disabled: true }, "colorUtils_colorUtilsCSS_compound_8__k096v4m"], [{ color: "neutral", disabled: true }, "colorUtils_colorUtilsCSS_compound_9__k096v4n"]] });
27
+ var colorUtilsVars = { text: "var(--vars_text__k096v40)", icon: "var(--vars_icon__k096v41)", borderColor: "var(--vars_borderColor__k096v42)" };
@@ -22,7 +22,9 @@ const AppRoot = /* @__PURE__ */ forwardRef(
22
22
  const {
23
23
  style: consumerStyle,
24
24
  className: consumerClassName,
25
- "data-testid": dataTestId = "app-root"
25
+ "data-testid": dataTestId = "app-root",
26
+ "data-dtrum-mask": dataDtrumMask,
27
+ "data-dtrum-allow": dataDtrumAllow
26
28
  } = props;
27
29
  const [messages, setMessages] = useState({});
28
30
  const { children } = props;
@@ -67,7 +69,9 @@ const AppRoot = /* @__PURE__ */ forwardRef(
67
69
  "data-testid": dataTestId,
68
70
  className: consumerClassName,
69
71
  style: consumerStyle,
70
- "data-theme": theme
72
+ "data-theme": theme,
73
+ "data-dtrum-mask": dataDtrumMask,
74
+ "data-dtrum-allow": dataDtrumAllow
71
75
  },
72
76
  /* @__PURE__ */ React.createElement(
73
77
  IntlProvider,
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "version": 3,
3
3
  "sources": ["../../../../../src/core/components/app-root/AppRoot.tsx"],
4
- "sourcesContent": ["import { isEmpty } from 'lodash-es';\nimport React, {\n type PropsWithChildren,\n forwardRef,\n useEffect,\n useLayoutEffect,\n useState,\n} from 'react';\nimport { IntlProvider, type MessageFormatElement } from 'react-intl';\n\nimport 'wicg-inert';\nimport { getLanguage, getTimezone } from '@dynatrace-sdk/user-preferences';\n\nimport './AppRoot.sty.js';\nimport { useCurrentTheme } from '../../hooks/useCurrentTheme.js';\nimport { FocusProvider } from '../../providers/FocusProvider.js';\nimport { type DataTestId } from '../../types/data-props.js';\nimport { type StylingProps } from '../../types/styling-props.js';\n\n/**\n * Gets the href value set in the <base> element to prefix fetches correctly.\n * Will always end with a `/` value\n */\nfunction getBaseHref(): string {\n const baseElement = document.querySelector('base');\n const href = baseElement?.href ?? '/';\n return href.endsWith('/') ? href : `${href}/`;\n}\n\n/** AppRoot component props. */\nexport type AppRootProps = PropsWithChildren<DataTestId & StylingProps>;\n\nconst defaultLanguage = 'en';\n/**\n * In order to have all the providers in place for rendering overlays, applying\n * global styles or internationalization, you need to wrap your app in the\n * `AppRoot`. If you're using the `dt-app` to create your app, this is\n * automatically taken care of and you can start working on your app without\n * further ado.\n */\nexport const AppRoot = /* @__PURE__ */ forwardRef<HTMLDivElement, AppRootProps>(\n (props, forwardedRef) => {\n const {\n style: consumerStyle,\n className: consumerClassName,\n 'data-testid': dataTestId = 'app-root',\n } = props;\n\n /** Messages that are used for the translation. */\n const [messages, setMessages] = useState<\n Record<string, string> | Record<string, MessageFormatElement[]>\n >({});\n\n const { children } = props;\n\n const theme = useCurrentTheme();\n const language = getLanguage();\n let timezone = getTimezone();\n try {\n new Intl.DateTimeFormat(language, { timeZone: timezone });\n } catch (error) {\n // If the passed timezone is not valid, we can fall back to the browsers\n // configured one.\n timezone = Intl.DateTimeFormat().resolvedOptions().timeZone;\n }\n\n /** Inject the font link into the head */\n useLayoutEffect(() => {\n // As we should not use @import within the createGlobalStyles\n // https://styled-components.com/docs/faqs#note-regarding-css-import-and-createglobalstyle\n // and we need to inject the fonts at run time to decouple font usage\n // from the cli build / deployment\n // we will inject the link tag here in the root on initial load.\n const link = document.createElement('link');\n\n link.rel = 'stylesheet';\n link.href = 'https://dt-cdn.net/fonts/fonts-v004.css';\n document.head.appendChild(link);\n return () => {\n document.head.removeChild(link);\n };\n }, []);\n\n /**\n * Synchronize the [data-theme] attribute to the root of the document\n * to have the design tokens defined in the cascade.\n */\n useLayoutEffect(() => {\n if (document !== undefined) {\n document.documentElement.setAttribute('data-theme', theme);\n }\n }, [theme]);\n\n useEffect(() => {\n if (language === 'en') {\n // Don't fetch translations for 'en' to avoid an additional render cycle.\n // The default messages are in english already.\n return;\n }\n\n fetch(`${getBaseHref()}lang/${language}.json`)\n .then((res) => {\n return res.json();\n })\n .then((receivedMessages) => {\n setMessages(receivedMessages);\n })\n .catch(() => {\n // Only set messages to a new empty object if the previous messages were not empty.\n // `setMessages({})` would make react believe that this is a new object and, hence, re-render.\n // By just returning `prev` if the messages were already empty, we can avoid the additional render.\n setMessages((prev) => (isEmpty(prev) ? prev : {}));\n });\n }, [language]);\n\n return (\n <div\n ref={forwardedRef}\n data-testid={dataTestId}\n className={consumerClassName}\n style={consumerStyle}\n data-theme={theme}\n >\n <IntlProvider\n locale={language}\n timeZone={timezone}\n messages={messages}\n defaultLocale={defaultLanguage}\n >\n <FocusProvider>{children}</FocusProvider>\n </IntlProvider>\n </div>\n );\n },\n);\n\n(AppRoot as typeof AppRoot & { displayName: string }).displayName = 'AppRoot';\n"],
5
- "mappings": "AAAA,SAAS,eAAe;AACxB,OAAO;AAAA,EAEL;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,OACK;AACP,SAAS,oBAA+C;AAExD,OAAO;AACP,SAAS,aAAa,mBAAmB;AAEzC,OAAO;AACP,SAAS,uBAAuB;AAChC,SAAS,qBAAqB;AAQ9B,SAAS,cAAsB;AAC7B,QAAM,cAAc,SAAS,cAAc,MAAM;AACjD,QAAM,OAAO,aAAa,QAAQ;AAClC,SAAO,KAAK,SAAS,GAAG,IAAI,OAAO,GAAG,IAAI;AAC5C;AAKA,MAAM,kBAAkB;AAQjB,MAAM,UAA0B;AAAA,EACrC,CAAC,OAAO,iBAAiB;AACvB,UAAM;AAAA,MACJ,OAAO;AAAA,MACP,WAAW;AAAA,MACX,eAAe,aAAa;AAAA,IAC9B,IAAI;AAGJ,UAAM,CAAC,UAAU,WAAW,IAAI,SAE9B,CAAC,CAAC;AAEJ,UAAM,EAAE,SAAS,IAAI;AAErB,UAAM,QAAQ,gBAAgB;AAC9B,UAAM,WAAW,YAAY;AAC7B,QAAI,WAAW,YAAY;AAC3B,QAAI;AACF,UAAI,KAAK,eAAe,UAAU,EAAE,UAAU,SAAS,CAAC;AAAA,IAC1D,SAAS,OAAO;AAGd,iBAAW,KAAK,eAAe,EAAE,gBAAgB,EAAE;AAAA,IACrD;AAGA,oBAAgB,MAAM;AAMpB,YAAM,OAAO,SAAS,cAAc,MAAM;AAE1C,WAAK,MAAM;AACX,WAAK,OAAO;AACZ,eAAS,KAAK,YAAY,IAAI;AAC9B,aAAO,MAAM;AACX,iBAAS,KAAK,YAAY,IAAI;AAAA,MAChC;AAAA,IACF,GAAG,CAAC,CAAC;AAML,oBAAgB,MAAM;AACpB,UAAI,aAAa,QAAW;AAC1B,iBAAS,gBAAgB,aAAa,cAAc,KAAK;AAAA,MAC3D;AAAA,IACF,GAAG,CAAC,KAAK,CAAC;AAEV,cAAU,MAAM;AACd,UAAI,aAAa,MAAM;AAGrB;AAAA,MACF;AAEA,YAAM,GAAG,YAAY,CAAC,QAAQ,QAAQ,OAAO,EAC1C,KAAK,CAAC,QAAQ;AACb,eAAO,IAAI,KAAK;AAAA,MAClB,CAAC,EACA,KAAK,CAAC,qBAAqB;AAC1B,oBAAY,gBAAgB;AAAA,MAC9B,CAAC,EACA,MAAM,MAAM;AAIX,oBAAY,CAAC,SAAU,QAAQ,IAAI,IAAI,OAAO,CAAC,CAAE;AAAA,MACnD,CAAC;AAAA,IACL,GAAG,CAAC,QAAQ,CAAC;AAEb,WACE;AAAA,MAAC;AAAA;AAAA,QACC,KAAK;AAAA,QACL,eAAa;AAAA,QACb,WAAW;AAAA,QACX,OAAO;AAAA,QACP,cAAY;AAAA;AAAA,MAEZ;AAAA,QAAC;AAAA;AAAA,UACC,QAAQ;AAAA,UACR,UAAU;AAAA,UACV;AAAA,UACA,eAAe;AAAA;AAAA,QAEf,oCAAC,qBAAe,QAAS;AAAA,MAC3B;AAAA,IACF;AAAA,EAEJ;AACF;AAEC,QAAqD,cAAc;",
4
+ "sourcesContent": ["import { isEmpty } from 'lodash-es';\nimport React, {\n type PropsWithChildren,\n forwardRef,\n useEffect,\n useLayoutEffect,\n useState,\n} from 'react';\nimport { IntlProvider, type MessageFormatElement } from 'react-intl';\n\nimport 'wicg-inert';\nimport { getLanguage, getTimezone } from '@dynatrace-sdk/user-preferences';\n\nimport './AppRoot.sty.js';\nimport { useCurrentTheme } from '../../hooks/useCurrentTheme.js';\nimport { FocusProvider } from '../../providers/FocusProvider.js';\nimport { type DataTestId } from '../../types/data-props.js';\nimport { type MaskingProps } from '../../types/masking-props.js';\nimport { type StylingProps } from '../../types/styling-props.js';\n\n/**\n * Gets the href value set in the <base> element to prefix fetches correctly.\n * Will always end with a `/` value\n */\nfunction getBaseHref(): string {\n const baseElement = document.querySelector('base');\n const href = baseElement?.href ?? '/';\n return href.endsWith('/') ? href : `${href}/`;\n}\n\n/**\n * @public\n * AppRoot component props.\n */\nexport type AppRootProps = PropsWithChildren<\n DataTestId & StylingProps & MaskingProps\n>;\n\nconst defaultLanguage = 'en';\n\n/**\n * @public\n * In order to have all the providers in place for rendering overlays, applying\n * global styles or internationalization, you need to wrap your app in the\n * `AppRoot`. If you're using the `dt-app` to create your app, this is\n * automatically taken care of and you can start working on your app without\n * further ado.\n */\nexport const AppRoot = /* @__PURE__ */ forwardRef<HTMLDivElement, AppRootProps>(\n (props, forwardedRef) => {\n const {\n style: consumerStyle,\n className: consumerClassName,\n 'data-testid': dataTestId = 'app-root',\n 'data-dtrum-mask': dataDtrumMask,\n 'data-dtrum-allow': dataDtrumAllow,\n } = props;\n\n /** Messages that are used for the translation. */\n const [messages, setMessages] = useState<\n Record<string, string> | Record<string, MessageFormatElement[]>\n >({});\n\n const { children } = props;\n\n const theme = useCurrentTheme();\n const language = getLanguage();\n let timezone = getTimezone();\n try {\n new Intl.DateTimeFormat(language, { timeZone: timezone });\n } catch (error) {\n // If the passed timezone is not valid, we can fall back to the browsers\n // configured one.\n timezone = Intl.DateTimeFormat().resolvedOptions().timeZone;\n }\n\n /** Inject the font link into the head */\n useLayoutEffect(() => {\n // As we should not use @import within the createGlobalStyles\n // https://styled-components.com/docs/faqs#note-regarding-css-import-and-createglobalstyle\n // and we need to inject the fonts at run time to decouple font usage\n // from the cli build / deployment\n // we will inject the link tag here in the root on initial load.\n const link = document.createElement('link');\n\n link.rel = 'stylesheet';\n link.href = 'https://dt-cdn.net/fonts/fonts-v004.css';\n document.head.appendChild(link);\n return () => {\n document.head.removeChild(link);\n };\n }, []);\n\n /**\n * Synchronize the [data-theme] attribute to the root of the document\n * to have the design tokens defined in the cascade.\n */\n useLayoutEffect(() => {\n if (document !== undefined) {\n document.documentElement.setAttribute('data-theme', theme);\n }\n }, [theme]);\n\n useEffect(() => {\n if (language === 'en') {\n // Don't fetch translations for 'en' to avoid an additional render cycle.\n // The default messages are in english already.\n return;\n }\n\n fetch(`${getBaseHref()}lang/${language}.json`)\n .then((res) => {\n return res.json();\n })\n .then((receivedMessages) => {\n setMessages(receivedMessages);\n })\n .catch(() => {\n // Only set messages to a new empty object if the previous messages were not empty.\n // `setMessages({})` would make react believe that this is a new object and, hence, re-render.\n // By just returning `prev` if the messages were already empty, we can avoid the additional render.\n setMessages((prev) => (isEmpty(prev) ? prev : {}));\n });\n }, [language]);\n\n return (\n <div\n ref={forwardedRef}\n data-testid={dataTestId}\n className={consumerClassName}\n style={consumerStyle}\n data-theme={theme}\n data-dtrum-mask={dataDtrumMask}\n data-dtrum-allow={dataDtrumAllow}\n >\n <IntlProvider\n locale={language}\n timeZone={timezone}\n messages={messages}\n defaultLocale={defaultLanguage}\n >\n <FocusProvider>{children}</FocusProvider>\n </IntlProvider>\n </div>\n );\n },\n);\n\n(AppRoot as typeof AppRoot & { displayName: string }).displayName = 'AppRoot';\n"],
5
+ "mappings": "AAAA,SAAS,eAAe;AACxB,OAAO;AAAA,EAEL;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,OACK;AACP,SAAS,oBAA+C;AAExD,OAAO;AACP,SAAS,aAAa,mBAAmB;AAEzC,OAAO;AACP,SAAS,uBAAuB;AAChC,SAAS,qBAAqB;AAS9B,SAAS,cAAsB;AAC7B,QAAM,cAAc,SAAS,cAAc,MAAM;AACjD,QAAM,OAAO,aAAa,QAAQ;AAClC,SAAO,KAAK,SAAS,GAAG,IAAI,OAAO,GAAG,IAAI;AAC5C;AAUA,MAAM,kBAAkB;AAUjB,MAAM,UAA0B;AAAA,EACrC,CAAC,OAAO,iBAAiB;AACvB,UAAM;AAAA,MACJ,OAAO;AAAA,MACP,WAAW;AAAA,MACX,eAAe,aAAa;AAAA,MAC5B,mBAAmB;AAAA,MACnB,oBAAoB;AAAA,IACtB,IAAI;AAGJ,UAAM,CAAC,UAAU,WAAW,IAAI,SAE9B,CAAC,CAAC;AAEJ,UAAM,EAAE,SAAS,IAAI;AAErB,UAAM,QAAQ,gBAAgB;AAC9B,UAAM,WAAW,YAAY;AAC7B,QAAI,WAAW,YAAY;AAC3B,QAAI;AACF,UAAI,KAAK,eAAe,UAAU,EAAE,UAAU,SAAS,CAAC;AAAA,IAC1D,SAAS,OAAO;AAGd,iBAAW,KAAK,eAAe,EAAE,gBAAgB,EAAE;AAAA,IACrD;AAGA,oBAAgB,MAAM;AAMpB,YAAM,OAAO,SAAS,cAAc,MAAM;AAE1C,WAAK,MAAM;AACX,WAAK,OAAO;AACZ,eAAS,KAAK,YAAY,IAAI;AAC9B,aAAO,MAAM;AACX,iBAAS,KAAK,YAAY,IAAI;AAAA,MAChC;AAAA,IACF,GAAG,CAAC,CAAC;AAML,oBAAgB,MAAM;AACpB,UAAI,aAAa,QAAW;AAC1B,iBAAS,gBAAgB,aAAa,cAAc,KAAK;AAAA,MAC3D;AAAA,IACF,GAAG,CAAC,KAAK,CAAC;AAEV,cAAU,MAAM;AACd,UAAI,aAAa,MAAM;AAGrB;AAAA,MACF;AAEA,YAAM,GAAG,YAAY,CAAC,QAAQ,QAAQ,OAAO,EAC1C,KAAK,CAAC,QAAQ;AACb,eAAO,IAAI,KAAK;AAAA,MAClB,CAAC,EACA,KAAK,CAAC,qBAAqB;AAC1B,oBAAY,gBAAgB;AAAA,MAC9B,CAAC,EACA,MAAM,MAAM;AAIX,oBAAY,CAAC,SAAU,QAAQ,IAAI,IAAI,OAAO,CAAC,CAAE;AAAA,MACnD,CAAC;AAAA,IACL,GAAG,CAAC,QAAQ,CAAC;AAEb,WACE;AAAA,MAAC;AAAA;AAAA,QACC,KAAK;AAAA,QACL,eAAa;AAAA,QACb,WAAW;AAAA,QACX,OAAO;AAAA,QACP,cAAY;AAAA,QACZ,mBAAiB;AAAA,QACjB,oBAAkB;AAAA;AAAA,MAElB;AAAA,QAAC;AAAA;AAAA,UACC,QAAQ;AAAA,UACR,UAAU;AAAA,UACV;AAAA,UACA,eAAe;AAAA;AAAA,QAEf,oCAAC,qBAAe,QAAS;AAAA,MAC3B;AAAA,IACF;AAAA,EAEJ;AACF;AAEC,QAAqD,cAAc;",
6
6
  "names": []
7
7
  }
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "version": 3,
3
3
  "sources": ["../../../../src/core/contexts/FocusContext.tsx"],
4
- "sourcesContent": ["import { createContext } from 'react';\n\nimport { Modality } from '../providers/FocusProvider.js';\n\n/**\n * Defines the contents of the FocusContext.\n * @internal\n */\nexport type FocusContextProps = {\n backgroundInertness?: boolean;\n modality: Modality;\n setBackgroundInertness: (value: boolean) => void;\n};\n\n/**\n * @internal\n *\n * This context keeps all information needed for proper focus management.\n * @param modality - currently used pointer device\n * @param backgroundInertness - if the background (behind overlays) is currently inert (inactive)\n * @param setBackgroundInertness - updates the backgrounds active status\n */\nexport const FocusContext = createContext<FocusContextProps>({\n modality: 'unknown',\n backgroundInertness: undefined,\n setBackgroundInertness: (value) => null,\n});\n"],
4
+ "sourcesContent": ["import { createContext } from 'react';\n\nimport type { Modality } from '../providers/FocusProvider.js';\n\n/**\n * Defines the contents of the FocusContext.\n * @internal\n */\nexport type FocusContextProps = {\n backgroundInertness?: boolean;\n modality: Modality;\n setBackgroundInertness: (value: boolean) => void;\n};\n\n/**\n * @internal\n *\n * This context keeps all information needed for proper focus management.\n * @param modality - currently used pointer device\n * @param backgroundInertness - if the background (behind overlays) is currently inert (inactive)\n * @param setBackgroundInertness - updates the backgrounds active status\n */\nexport const FocusContext = createContext<FocusContextProps>({\n modality: 'unknown',\n backgroundInertness: undefined,\n setBackgroundInertness: (value) => null,\n});\n"],
5
5
  "mappings": "AAAA,SAAS,qBAAqB;AAsBvB,MAAM,eAAe,cAAiC;AAAA,EAC3D,UAAU;AAAA,EACV,qBAAqB;AAAA,EACrB,wBAAwB,CAAC,UAAU;AACrC,CAAC;",
6
6
  "names": []
7
7
  }
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "version": 3,
3
3
  "sources": ["../../../../src/core/hooks/useCurrentTheme.tsx"],
4
- "sourcesContent": ["import { useEffect, useMemo, useState } from 'react';\n\nimport { getTheme } from '@dynatrace-sdk/user-preferences';\n\nimport { isBrowser } from '../utils/isBrowser.js';\n\n/** Returns the current theme based on sdk-setting or browsers preferred color-scheme */\nexport function useCurrentTheme(): 'light' | 'dark' {\n const sdkTheme = useMemo(() => {\n return getTheme();\n }, []);\n\n if (sdkTheme === 'dark' || sdkTheme === 'light') {\n return sdkTheme;\n }\n\n if (!isBrowser) {\n return 'light';\n }\n\n // suppressing the rules of hooks because the sdkTheme is a constant that cannot\n // change through the applications' lifecycle.\n // eslint-disable-next-line react-hooks/rules-of-hooks\n const themeQuery = useMemo(\n () => window && window.matchMedia('(prefers-color-scheme: dark)'),\n [],\n );\n\n // suppressing the rules of hooks because the sdkTheme is a constant that cannot\n // change through the applications' lifecycle.\n // eslint-disable-next-line react-hooks/rules-of-hooks\n const [currentTheme, setCurrentTheme] = useState<'light' | 'dark'>(\n themeQuery.matches ? 'dark' : 'light',\n );\n\n // suppressing the rules of hooks because the sdkTheme is a constant that cannot\n // change through the applications' lifecycle.\n // eslint-disable-next-line react-hooks/rules-of-hooks\n useEffect(() => {\n const handlePrefersColorSchemeChange = () => {\n const prefersDark = themeQuery.matches;\n setCurrentTheme(prefersDark ? 'dark' : 'light');\n };\n\n themeQuery.addEventListener('change', handlePrefersColorSchemeChange);\n return () => {\n themeQuery.removeEventListener('change', handlePrefersColorSchemeChange);\n };\n }, [themeQuery]);\n\n return currentTheme;\n}\n"],
5
- "mappings": "AAAA,SAAS,WAAW,SAAS,gBAAgB;AAE7C,SAAS,gBAAgB;AAEzB,SAAS,iBAAiB;AAGnB,SAAS,kBAAoC;AAClD,QAAM,WAAW,QAAQ,MAAM;AAC7B,WAAO,SAAS;AAAA,EAClB,GAAG,CAAC,CAAC;AAEL,MAAI,aAAa,UAAU,aAAa,SAAS;AAC/C,WAAO;AAAA,EACT;AAEA,MAAI,CAAC,WAAW;AACd,WAAO;AAAA,EACT;AAKA,QAAM,aAAa;AAAA,IACjB,MAAM,UAAU,OAAO,WAAW,8BAA8B;AAAA,IAChE,CAAC;AAAA,EACH;AAKA,QAAM,CAAC,cAAc,eAAe,IAAI;AAAA,IACtC,WAAW,UAAU,SAAS;AAAA,EAChC;AAKA,YAAU,MAAM;AACd,UAAM,iCAAiC,MAAM;AAC3C,YAAM,cAAc,WAAW;AAC/B,sBAAgB,cAAc,SAAS,OAAO;AAAA,IAChD;AAEA,eAAW,iBAAiB,UAAU,8BAA8B;AACpE,WAAO,MAAM;AACX,iBAAW,oBAAoB,UAAU,8BAA8B;AAAA,IACzE;AAAA,EACF,GAAG,CAAC,UAAU,CAAC;AAEf,SAAO;AACT;",
4
+ "sourcesContent": ["import { useEffect, useMemo, useState } from 'react';\n\nimport { getTheme } from '@dynatrace-sdk/user-preferences';\n\nimport { isBrowser } from '../utils/isBrowser.js';\n\n/**\n * @public\n * Returns the current theme based on sdk-setting or browsers preferred color-scheme\n */\nexport function useCurrentTheme(): 'light' | 'dark' {\n const sdkTheme = useMemo(() => {\n return getTheme();\n }, []);\n\n if (sdkTheme === 'dark' || sdkTheme === 'light') {\n return sdkTheme;\n }\n\n if (!isBrowser) {\n return 'light';\n }\n\n // suppressing the rules of hooks because the sdkTheme is a constant that cannot\n // change through the applications' lifecycle.\n // eslint-disable-next-line react-hooks/rules-of-hooks\n const themeQuery = useMemo(\n () => window && window.matchMedia('(prefers-color-scheme: dark)'),\n [],\n );\n\n // suppressing the rules of hooks because the sdkTheme is a constant that cannot\n // change through the applications' lifecycle.\n // eslint-disable-next-line react-hooks/rules-of-hooks\n const [currentTheme, setCurrentTheme] = useState<'light' | 'dark'>(\n themeQuery.matches ? 'dark' : 'light',\n );\n\n // suppressing the rules of hooks because the sdkTheme is a constant that cannot\n // change through the applications' lifecycle.\n // eslint-disable-next-line react-hooks/rules-of-hooks\n useEffect(() => {\n const handlePrefersColorSchemeChange = () => {\n const prefersDark = themeQuery.matches;\n setCurrentTheme(prefersDark ? 'dark' : 'light');\n };\n\n themeQuery.addEventListener('change', handlePrefersColorSchemeChange);\n return () => {\n themeQuery.removeEventListener('change', handlePrefersColorSchemeChange);\n };\n }, [themeQuery]);\n\n return currentTheme;\n}\n"],
5
+ "mappings": "AAAA,SAAS,WAAW,SAAS,gBAAgB;AAE7C,SAAS,gBAAgB;AAEzB,SAAS,iBAAiB;AAMnB,SAAS,kBAAoC;AAClD,QAAM,WAAW,QAAQ,MAAM;AAC7B,WAAO,SAAS;AAAA,EAClB,GAAG,CAAC,CAAC;AAEL,MAAI,aAAa,UAAU,aAAa,SAAS;AAC/C,WAAO;AAAA,EACT;AAEA,MAAI,CAAC,WAAW;AACd,WAAO;AAAA,EACT;AAKA,QAAM,aAAa;AAAA,IACjB,MAAM,UAAU,OAAO,WAAW,8BAA8B;AAAA,IAChE,CAAC;AAAA,EACH;AAKA,QAAM,CAAC,cAAc,eAAe,IAAI;AAAA,IACtC,WAAW,UAAU,SAAS;AAAA,EAChC;AAKA,YAAU,MAAM;AACd,UAAM,iCAAiC,MAAM;AAC3C,YAAM,cAAc,WAAW;AAC/B,sBAAgB,cAAc,SAAS,OAAO;AAAA,IAChD;AAEA,eAAW,iBAAiB,UAAU,8BAA8B;AACpE,WAAO,MAAM;AACX,iBAAW,oBAAoB,UAAU,8BAA8B;AAAA,IACzE;AAAA,EACF,GAAG,CAAC,UAAU,CAAC;AAEf,SAAO;AACT;",
6
6
  "names": []
7
7
  }
@@ -0,0 +1,33 @@
1
+ import { isEqual } from "lodash-es";
2
+ import { useRef, useState } from "react";
3
+ function _useFontsUpdated(callback) {
4
+ const [fontsUpdated, setFontsUpdated] = useState(false);
5
+ const prevFontFamilies = useRef();
6
+ const fontFamilies = [];
7
+ const firstRender = useRef(true);
8
+ if (document.fonts) {
9
+ if (firstRender.current) {
10
+ const loadedFontFamilies = [];
11
+ document.fonts.forEach(
12
+ (fontFace) => loadedFontFamilies.push(`${fontFace.family} ${fontFace.weight}`)
13
+ );
14
+ prevFontFamilies.current = loadedFontFamilies;
15
+ firstRender.current = false;
16
+ }
17
+ document.fonts.ready.then((fontFaceSet) => {
18
+ fontFaceSet.forEach(
19
+ (fontFace) => fontFamilies.push(`${fontFace.family} ${fontFace.weight}`)
20
+ );
21
+ if (!isEqual(prevFontFamilies.current, fontFamilies)) {
22
+ prevFontFamilies.current = fontFamilies;
23
+ callback?.();
24
+ setFontsUpdated(true);
25
+ }
26
+ });
27
+ }
28
+ return fontsUpdated;
29
+ }
30
+ export {
31
+ _useFontsUpdated
32
+ };
33
+ //# sourceMappingURL=useFontsUpdated.js.map
@@ -0,0 +1,7 @@
1
+ {
2
+ "version": 3,
3
+ "sources": ["../../../../src/core/hooks/useFontsUpdated.ts"],
4
+ "sourcesContent": ["import { isEqual } from 'lodash-es';\nimport { useRef, useState } from 'react';\n\n/**\n * Hook that checks if the initially loaded fonts were updated.\n * Used to trigger remeasuring in the DataTable (autoWidth) and TextEllipsis once all fonts are loaded.\n *\n * @param callback - optionally pass a function to be executed once when the fonts were updated\n * @returns boolean whether the fonts have changed\n * @internal\n */\nexport function _useFontsUpdated(callback?: () => void): boolean {\n const [fontsUpdated, setFontsUpdated] = useState(false);\n const prevFontFamilies = useRef<string[]>();\n const fontFamilies: string[] = [];\n const firstRender = useRef(true);\n\n if (document.fonts) {\n // gather the font families that are already loaded\n if (firstRender.current) {\n const loadedFontFamilies: string[] = [];\n document.fonts.forEach((fontFace: FontFace) =>\n loadedFontFamilies.push(`${fontFace.family} ${fontFace.weight}`),\n );\n prevFontFamilies.current = loadedFontFamilies;\n firstRender.current = false;\n }\n\n document.fonts.ready.then((fontFaceSet: FontFaceSet) => {\n fontFaceSet.forEach((fontFace: FontFace) =>\n fontFamilies.push(`${fontFace.family} ${fontFace.weight}`),\n );\n\n if (!isEqual(prevFontFamilies.current, fontFamilies)) {\n prevFontFamilies.current = fontFamilies;\n callback?.();\n setFontsUpdated(true);\n }\n });\n }\n\n return fontsUpdated;\n}\n"],
5
+ "mappings": "AAAA,SAAS,eAAe;AACxB,SAAS,QAAQ,gBAAgB;AAU1B,SAAS,iBAAiB,UAAgC;AAC/D,QAAM,CAAC,cAAc,eAAe,IAAI,SAAS,KAAK;AACtD,QAAM,mBAAmB,OAAiB;AAC1C,QAAM,eAAyB,CAAC;AAChC,QAAM,cAAc,OAAO,IAAI;AAE/B,MAAI,SAAS,OAAO;AAElB,QAAI,YAAY,SAAS;AACvB,YAAM,qBAA+B,CAAC;AACtC,eAAS,MAAM;AAAA,QAAQ,CAAC,aACtB,mBAAmB,KAAK,GAAG,SAAS,MAAM,IAAI,SAAS,MAAM,EAAE;AAAA,MACjE;AACA,uBAAiB,UAAU;AAC3B,kBAAY,UAAU;AAAA,IACxB;AAEA,aAAS,MAAM,MAAM,KAAK,CAAC,gBAA6B;AACtD,kBAAY;AAAA,QAAQ,CAAC,aACnB,aAAa,KAAK,GAAG,SAAS,MAAM,IAAI,SAAS,MAAM,EAAE;AAAA,MAC3D;AAEA,UAAI,CAAC,QAAQ,iBAAiB,SAAS,YAAY,GAAG;AACpD,yBAAiB,UAAU;AAC3B,mBAAW;AACX,wBAAgB,IAAI;AAAA,MACtB;AAAA,IACF,CAAC;AAAA,EACH;AAEA,SAAO;AACT;",
6
+ "names": []
7
+ }
@@ -0,0 +1,16 @@
1
+ import { useCallback } from "react";
2
+ function useMergeRefs(refs) {
3
+ return useCallback((value) => {
4
+ for (const ref of refs) {
5
+ if (typeof ref === "function") {
6
+ ref(value);
7
+ } else if (ref !== void 0 && ref !== null) {
8
+ ref.current = value;
9
+ }
10
+ }
11
+ }, refs);
12
+ }
13
+ export {
14
+ useMergeRefs
15
+ };
16
+ //# sourceMappingURL=useMergeRefs.js.map
@@ -0,0 +1,7 @@
1
+ {
2
+ "version": 3,
3
+ "sources": ["../../../../src/core/hooks/useMergeRefs.ts"],
4
+ "sourcesContent": ["import React, { useCallback } from 'react';\n\n/**\n * If you have multiple references (e.g. from different hooks) you need to apply to\n * the same element, you can use the `useMergeRefs` hook to combine them into one\n * reference.\n */\nexport function useMergeRefs<T = unknown>(\n refs: Array<\n | React.MutableRefObject<T>\n | React.LegacyRef<T>\n | React.Dispatch<React.SetStateAction<T | null>>\n | undefined\n >,\n): React.RefCallback<T> {\n return useCallback((value) => {\n for (const ref of refs) {\n if (typeof ref === 'function') {\n ref(value);\n } else if (ref !== undefined && ref !== null) {\n (ref as React.MutableRefObject<T | null>).current = value;\n }\n }\n }, refs); // eslint-disable-line react-hooks/exhaustive-deps\n}\n"],
5
+ "mappings": "AAAA,SAAgB,mBAAmB;AAO5B,SAAS,aACd,MAMsB;AACtB,SAAO,YAAY,CAAC,UAAU;AAC5B,eAAW,OAAO,MAAM;AACtB,UAAI,OAAO,QAAQ,YAAY;AAC7B,YAAI,KAAK;AAAA,MACX,WAAW,QAAQ,UAAa,QAAQ,MAAM;AAC5C,QAAC,IAAyC,UAAU;AAAA,MACtD;AAAA,IACF;AAAA,EACF,GAAG,IAAI;AACT;",
6
+ "names": []
7
+ }
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "version": 3,
3
3
  "sources": ["../../../src/core/index.ts"],
4
- "sourcesContent": ["export { AppRoot, type AppRootProps } from './components/app-root/AppRoot.js';\nexport {\n FocusScope as _FocusScope,\n type FocusScopeProps as _FocusScopeProps,\n} from './components/focus-scope/FocusScope.js';\n\nexport { type FocusContextProps as _FocusContextProps } from './contexts/FocusContext.js';\n\nexport { useCurrentTheme } from './hooks/useCurrentTheme.js';\nexport { useFocusContext as _useFocusContext } from './hooks/useFocusContext.js';\nexport {\n FocusProvider as _FocusProvider,\n type Modality as _Modality,\n} from './providers/FocusProvider.js';\nexport type { DataTestId } from './types/data-props.js';\nexport type { StylingProps } from './types/styling-props.js';\nexport type { WithChildren } from './types/with-children.js';\n\nexport { attemptFocus as _attemptFocus } from './utils/focus-management/attempt-focus.js';\nexport { focusFirstDescendant as _focusFirstDescendant } from './utils/focus-management/focus-first-descendant.js';\nexport { getFirstFocusableChild as _getFirstFocusableChild } from './utils/focus-management/get-first-focusable-child.js';\nexport { getLastFocusableChild as _getLastFocusableChild } from './utils/focus-management/get-last-focusable-child.js';\nexport { isFocusable as _isFocusable } from './utils/focus-management/is-focusable.js';\nexport { isBrowser as _isBrowser } from './utils/isBrowser.js';\nexport {\n mergeProps as _mergeProps,\n type NullToObject as _NullToObject,\n type TupleTypes as _TupleTypes,\n type UnionToIntersection as _UnionToIntersection,\n} from './utils/merge-props.js';\n"],
5
- "mappings": "AAAA,SAAS,eAAkC;AAC3C;AAAA,EACgB;AAAA,OAET;AAIP,SAAS,uBAAuB;AAChC,SAA4B,uBAAwB;AACpD;AAAA,EACmB;AAAA,OAEZ;AAKP,SAAyB,oBAAqB;AAC9C,SAAiC,4BAA6B;AAC9D,SAAmC,8BAA+B;AAClE,SAAkC,6BAA8B;AAChE,SAAwB,mBAAoB;AAC5C,SAAsB,iBAAkB;AACxC;AAAA,EACgB;AAAA,OAIT;",
4
+ "sourcesContent": ["export { AppRoot, type AppRootProps } from './components/app-root/AppRoot.js';\nexport {\n FocusScope as _FocusScope,\n type FocusScopeProps as _FocusScopeProps,\n} from './components/focus-scope/FocusScope.js';\n\nexport { type FocusContextProps as _FocusContextProps } from './contexts/FocusContext.js';\n\nexport { useCurrentTheme } from './hooks/useCurrentTheme.js';\nexport { useFocusContext as _useFocusContext } from './hooks/useFocusContext.js';\nexport {\n FocusProvider as _FocusProvider,\n type Modality as _Modality,\n} from './providers/FocusProvider.js';\nexport type { MaskingProps } from './types/masking-props.js';\nexport type { DataTestId } from './types/data-props.js';\nexport type { StylingProps } from './types/styling-props.js';\nexport type { WithChildren } from './types/with-children.js';\n\nexport { attemptFocus as _attemptFocus } from './utils/focus-management/attempt-focus.js';\nexport { focusFirstDescendant as _focusFirstDescendant } from './utils/focus-management/focus-first-descendant.js';\nexport { getFirstFocusableChild as _getFirstFocusableChild } from './utils/focus-management/get-first-focusable-child.js';\nexport { getLastFocusableChild as _getLastFocusableChild } from './utils/focus-management/get-last-focusable-child.js';\nexport { isFocusable as _isFocusable } from './utils/focus-management/is-focusable.js';\nexport { isBrowser as _isBrowser } from './utils/isBrowser.js';\nexport {\n mergeProps as _mergeProps,\n type NullToObject as _NullToObject,\n type TupleTypes as _TupleTypes,\n type UnionToIntersection as _UnionToIntersection,\n} from './utils/merge-props.js';\n\nexport type { AriaLabelingProps } from './types/a11y-props.js';\nexport type { DOMProps } from './types/dom.js';\nexport type {\n PolymorphicComponentProps,\n PolymorphProps,\n PolymorphOwnProps,\n} from './types/polymorph.js';\nexport { type _HeadingLevel, type _HeadingTag } from './types/heading.js';\n"],
5
+ "mappings": "AAAA,SAAS,eAAkC;AAC3C;AAAA,EACgB;AAAA,OAET;AAIP,SAAS,uBAAuB;AAChC,SAA4B,uBAAwB;AACpD;AAAA,EACmB;AAAA,OAEZ;AAMP,SAAyB,oBAAqB;AAC9C,SAAiC,4BAA6B;AAC9D,SAAmC,8BAA+B;AAClE,SAAkC,6BAA8B;AAChE,SAAwB,mBAAoB;AAC5C,SAAsB,iBAAkB;AACxC;AAAA,EACgB;AAAA,OAIT;",
6
6
  "names": []
7
7
  }
@@ -0,0 +1,88 @@
1
+ .focusRing_focusRingCSS__z2r50s3 {
2
+ outline: none;
3
+ }
4
+ .focusRing_focusRingCSS__z2r50s3:focus-visible {
5
+ outline: none;
6
+ }
7
+ .focusRing_focusRingCSS_minimal_true__z2r50s4 {
8
+ border-radius: calc(var(--dt-borders-radius-field-subdued, 4px) / 2);
9
+ box-shadow: inset 0 0 0 var(--dt-borders-width-default, 1px) var(--outerShadow__z2r50s0);
10
+ background-color: var(--backgroundColor__z2r50s2);
11
+ }
12
+ .focusRing_focusRingCSS_minimal_false__z2r50s5.focusRing_focusRingCSS_minimal_false__z2r50s5 {
13
+ box-shadow: inset 0 0 0 var(--dt-borders-width-emphasized, 2px) var(--outerShadow__z2r50s0), inset 0 0 0 calc(var(--dt-borders-width-emphasized, 2px) + 1px) var(--innerShadow__z2r50s1);
14
+ }
15
+ .focusRing_focusRingCSS_variant_neutral__z2r50s6 {
16
+ --outerShadow__z2r50s0: var(--dt-colors-border-neutral-accent, #545587);
17
+ --innerShadow__z2r50s1: var(--dt-colors-border-neutral-default, #d2d3e1);
18
+ --backgroundColor__z2r50s2: var(--dt-colors-background-field-neutral-emphasized, #dadbe7);
19
+ }
20
+ .focusRing_focusRingCSS_variant_primary__z2r50s7 {
21
+ --outerShadow__z2r50s0: var(--dt-colors-border-primary-accent, #454cc9);
22
+ --innerShadow__z2r50s1: var(--dt-colors-border-primary-default, #ccd3f3);
23
+ --backgroundColor__z2r50s2: var(--dt-colors-background-field-primary-emphasized, #d6dbf4);
24
+ }
25
+ .focusRing_focusRingCSS_variant_success__z2r50s8 {
26
+ --outerShadow__z2r50s0: var(--dt-colors-border-success-accent, #2c6360);
27
+ --innerShadow__z2r50s1: var(--dt-colors-border-success-default, #cad6d7);
28
+ --backgroundColor__z2r50s2: var(--dt-colors-background-field-success-emphasized, #d4dddf);
29
+ }
30
+ .focusRing_focusRingCSS_variant_warning__z2r50s9 {
31
+ --outerShadow__z2r50s0: var(--dt-colors-border-warning-accent, #805100);
32
+ --innerShadow__z2r50s1: var(--dt-colors-border-warning-default, #f4e5d5);
33
+ --backgroundColor__z2r50s2: var(--dt-colors-background-field-warning-emphasized, #f4e8de);
34
+ }
35
+ .focusRing_focusRingCSS_variant_critical__z2r50sa {
36
+ --outerShadow__z2r50s0: var(--dt-colors-border-critical-accent, #b80031);
37
+ --innerShadow__z2r50s1: var(--dt-colors-border-critical-default, #f1cdcf);
38
+ --backgroundColor__z2r50s2: var(--dt-colors-background-field-critical-emphasized, #f2d7d9);
39
+ }
40
+ .focusRing_focusRingCSS_variant_onAccent__z2r50sb {
41
+ --outerShadow__z2r50s0: var(--dt-colors-border-on-accent-default, #f3f3f7);
42
+ --innerShadow__z2r50s1: var(--dt-colors-border-on-accent-default, #f3f3f7);
43
+ --backgroundColor__z2r50s2: var(--dt-colors-background-field-on-accent-emphasized, #f3f3f733);
44
+ }
45
+ .focusRing_focusRingFocusWithinCSS__z2r50sc:focus-within {
46
+ outline: none;
47
+ :focus-visible {
48
+ outline: none;
49
+ }
50
+ }
51
+ .focusRing_focusRingFocusWithinCSS_minimal_true__z2r50sd:focus-within {
52
+ border-radius: calc(var(--dt-borders-radius-field-subdued, 4px) / 2);
53
+ box-shadow: inset 0 0 0 var(--dt-borders-width-default, 1px) var(--outerShadow__z2r50s0);
54
+ background-color: var(--backgroundColor__z2r50s2);
55
+ }
56
+ .focusRing_focusRingFocusWithinCSS_minimal_false__z2r50se:focus-within {
57
+ box-shadow: inset 0 0 0 var(--dt-borders-width-emphasized, 2px) var(--outerShadow__z2r50s0), inset 0 0 0 calc(var(--dt-borders-width-emphasized, 2px) + 1px) var(--innerShadow__z2r50s1);
58
+ }
59
+ .focusRing_focusRingFocusWithinCSS_variant_neutral__z2r50sf {
60
+ --outerShadow__z2r50s0: var(--dt-colors-border-neutral-accent, #545587);
61
+ --innerShadow__z2r50s1: var(--dt-colors-border-neutral-default, #d2d3e1);
62
+ --backgroundColor__z2r50s2: var(--dt-colors-background-field-neutral-emphasized, #dadbe7);
63
+ }
64
+ .focusRing_focusRingFocusWithinCSS_variant_primary__z2r50sg {
65
+ --outerShadow__z2r50s0: var(--dt-colors-border-primary-accent, #454cc9);
66
+ --innerShadow__z2r50s1: var(--dt-colors-border-primary-default, #ccd3f3);
67
+ --backgroundColor__z2r50s2: var(--dt-colors-background-field-primary-emphasized, #d6dbf4);
68
+ }
69
+ .focusRing_focusRingFocusWithinCSS_variant_success__z2r50sh {
70
+ --outerShadow__z2r50s0: var(--dt-colors-border-success-accent, #2c6360);
71
+ --innerShadow__z2r50s1: var(--dt-colors-border-success-default, #cad6d7);
72
+ --backgroundColor__z2r50s2: var(--dt-colors-background-field-success-emphasized, #d4dddf);
73
+ }
74
+ .focusRing_focusRingFocusWithinCSS_variant_warning__z2r50si {
75
+ --outerShadow__z2r50s0: var(--dt-colors-border-warning-accent, #805100);
76
+ --innerShadow__z2r50s1: var(--dt-colors-border-warning-default, #f4e5d5);
77
+ --backgroundColor__z2r50s2: var(--dt-colors-background-field-warning-emphasized, #f4e8de);
78
+ }
79
+ .focusRing_focusRingFocusWithinCSS_variant_critical__z2r50sj {
80
+ --outerShadow__z2r50s0: var(--dt-colors-border-critical-accent, #b80031);
81
+ --innerShadow__z2r50s1: var(--dt-colors-border-critical-default, #f1cdcf);
82
+ --backgroundColor__z2r50s2: var(--dt-colors-background-field-critical-emphasized, #f2d7d9);
83
+ }
84
+ .focusRing_focusRingFocusWithinCSS_variant_onAccent__z2r50sk {
85
+ --outerShadow__z2r50s0: var(--dt-colors-border-on-accent-default, #f3f3f7);
86
+ --innerShadow__z2r50s1: var(--dt-colors-border-on-accent-default, #f3f3f7);
87
+ --backgroundColor__z2r50s2: var(--dt-colors-background-field-on-accent-emphasized, #f3f3f733);
88
+ }
@@ -0,0 +1,9 @@
1
+ import "./focusRing.css";
2
+ import { createRuntimeFn as _7a468 } from "@vanilla-extract/recipes/createRuntimeFn";
3
+ var focusRingCSS = _7a468({ defaultClassName: "focusRing_focusRingCSS__z2r50s3", variantClassNames: { minimal: { true: "focusRing_focusRingCSS_minimal_true__z2r50s4", false: "focusRing_focusRingCSS_minimal_false__z2r50s5" }, variant: { neutral: "focusRing_focusRingCSS_variant_neutral__z2r50s6", primary: "focusRing_focusRingCSS_variant_primary__z2r50s7", success: "focusRing_focusRingCSS_variant_success__z2r50s8", warning: "focusRing_focusRingCSS_variant_warning__z2r50s9", critical: "focusRing_focusRingCSS_variant_critical__z2r50sa", onAccent: "focusRing_focusRingCSS_variant_onAccent__z2r50sb" } }, defaultVariants: {}, compoundVariants: [] });
4
+ var focusRingFocusWithinCSS = _7a468({ defaultClassName: "focusRing_focusRingFocusWithinCSS__z2r50sc", variantClassNames: { minimal: { true: "focusRing_focusRingFocusWithinCSS_minimal_true__z2r50sd", false: "focusRing_focusRingFocusWithinCSS_minimal_false__z2r50se" }, variant: { neutral: "focusRing_focusRingFocusWithinCSS_variant_neutral__z2r50sf", primary: "focusRing_focusRingFocusWithinCSS_variant_primary__z2r50sg", success: "focusRing_focusRingFocusWithinCSS_variant_success__z2r50sh", warning: "focusRing_focusRingFocusWithinCSS_variant_warning__z2r50si", critical: "focusRing_focusRingFocusWithinCSS_variant_critical__z2r50sj", onAccent: "focusRing_focusRingFocusWithinCSS_variant_onAccent__z2r50sk" } }, defaultVariants: {}, compoundVariants: [] });
5
+ export {
6
+ focusRingCSS,
7
+ focusRingFocusWithinCSS
8
+ };
9
+ //# sourceMappingURL=focusRing.sty.js.map
@@ -0,0 +1,7 @@
1
+ {
2
+ "version": 3,
3
+ "sources": ["../../../../src/core/styles/focusRing.css.ts"],
4
+ "sourcesContent": ["import './focusRing.css';\nimport { createRuntimeFn as _7a468 } from '@vanilla-extract/recipes/createRuntimeFn';\nexport var focusRingCSS = _7a468({defaultClassName:'focusRing_focusRingCSS__z2r50s3',variantClassNames:{minimal:{true:'focusRing_focusRingCSS_minimal_true__z2r50s4',false:'focusRing_focusRingCSS_minimal_false__z2r50s5'},variant:{neutral:'focusRing_focusRingCSS_variant_neutral__z2r50s6',primary:'focusRing_focusRingCSS_variant_primary__z2r50s7',success:'focusRing_focusRingCSS_variant_success__z2r50s8',warning:'focusRing_focusRingCSS_variant_warning__z2r50s9',critical:'focusRing_focusRingCSS_variant_critical__z2r50sa',onAccent:'focusRing_focusRingCSS_variant_onAccent__z2r50sb'}},defaultVariants:{},compoundVariants:[]});\nexport var focusRingFocusWithinCSS = _7a468({defaultClassName:'focusRing_focusRingFocusWithinCSS__z2r50sc',variantClassNames:{minimal:{true:'focusRing_focusRingFocusWithinCSS_minimal_true__z2r50sd',false:'focusRing_focusRingFocusWithinCSS_minimal_false__z2r50se'},variant:{neutral:'focusRing_focusRingFocusWithinCSS_variant_neutral__z2r50sf',primary:'focusRing_focusRingFocusWithinCSS_variant_primary__z2r50sg',success:'focusRing_focusRingFocusWithinCSS_variant_success__z2r50sh',warning:'focusRing_focusRingFocusWithinCSS_variant_warning__z2r50si',critical:'focusRing_focusRingFocusWithinCSS_variant_critical__z2r50sj',onAccent:'focusRing_focusRingFocusWithinCSS_variant_onAccent__z2r50sk'}},defaultVariants:{},compoundVariants:[]});"],
5
+ "mappings": "AAAA,OAAO;AACP,SAAS,mBAAmB,cAAc;AACnC,IAAI,eAAe,OAAO,EAAC,kBAAiB,mCAAkC,mBAAkB,EAAC,SAAQ,EAAC,MAAK,gDAA+C,OAAM,gDAA+C,GAAE,SAAQ,EAAC,SAAQ,mDAAkD,SAAQ,mDAAkD,SAAQ,mDAAkD,SAAQ,mDAAkD,UAAS,oDAAmD,UAAS,mDAAkD,EAAC,GAAE,iBAAgB,CAAC,GAAE,kBAAiB,CAAC,EAAC,CAAC;AACvmB,IAAI,0BAA0B,OAAO,EAAC,kBAAiB,8CAA6C,mBAAkB,EAAC,SAAQ,EAAC,MAAK,2DAA0D,OAAM,2DAA0D,GAAE,SAAQ,EAAC,SAAQ,8DAA6D,SAAQ,8DAA6D,SAAQ,8DAA6D,SAAQ,8DAA6D,UAAS,+DAA8D,UAAS,8DAA6D,EAAC,GAAE,iBAAgB,CAAC,GAAE,kBAAiB,CAAC,EAAC,CAAC;",
6
+ "names": []
7
+ }