@metamask-previews/design-system-shared 0.6.0-preview.dbe1fac → 0.7.0-preview.4ce710b

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 (58) hide show
  1. package/CHANGELOG.md +14 -1
  2. package/dist/index.cjs +14 -1
  3. package/dist/index.cjs.map +1 -1
  4. package/dist/index.d.cts +3 -0
  5. package/dist/index.d.cts.map +1 -1
  6. package/dist/index.d.mts +3 -0
  7. package/dist/index.d.mts.map +1 -1
  8. package/dist/index.mjs +5 -0
  9. package/dist/index.mjs.map +1 -1
  10. package/dist/types/AvatarAccount/AvatarAccount.types.cjs +24 -0
  11. package/dist/types/AvatarAccount/AvatarAccount.types.cjs.map +1 -0
  12. package/dist/types/AvatarAccount/AvatarAccount.types.d.cts +51 -0
  13. package/dist/types/AvatarAccount/AvatarAccount.types.d.cts.map +1 -0
  14. package/dist/types/AvatarAccount/AvatarAccount.types.d.mts +51 -0
  15. package/dist/types/AvatarAccount/AvatarAccount.types.d.mts.map +1 -0
  16. package/dist/types/AvatarAccount/AvatarAccount.types.mjs +21 -0
  17. package/dist/types/AvatarAccount/AvatarAccount.types.mjs.map +1 -0
  18. package/dist/types/AvatarAccount/index.cjs +7 -0
  19. package/dist/types/AvatarAccount/index.cjs.map +1 -0
  20. package/dist/types/AvatarAccount/index.d.cts +2 -0
  21. package/dist/types/AvatarAccount/index.d.cts.map +1 -0
  22. package/dist/types/AvatarAccount/index.d.mts +2 -0
  23. package/dist/types/AvatarAccount/index.d.mts.map +1 -0
  24. package/dist/types/AvatarAccount/index.mjs +2 -0
  25. package/dist/types/AvatarAccount/index.mjs.map +1 -0
  26. package/dist/types/AvatarToken/AvatarToken.types.cjs +6 -0
  27. package/dist/types/AvatarToken/AvatarToken.types.cjs.map +1 -0
  28. package/dist/types/AvatarToken/AvatarToken.types.d.cts +33 -0
  29. package/dist/types/AvatarToken/AvatarToken.types.d.cts.map +1 -0
  30. package/dist/types/AvatarToken/AvatarToken.types.d.mts +33 -0
  31. package/dist/types/AvatarToken/AvatarToken.types.d.mts.map +1 -0
  32. package/dist/types/AvatarToken/AvatarToken.types.mjs +3 -0
  33. package/dist/types/AvatarToken/AvatarToken.types.mjs.map +1 -0
  34. package/dist/types/AvatarToken/index.cjs +6 -0
  35. package/dist/types/AvatarToken/index.cjs.map +1 -0
  36. package/dist/types/AvatarToken/index.d.cts +2 -0
  37. package/dist/types/AvatarToken/index.d.cts.map +1 -0
  38. package/dist/types/AvatarToken/index.d.mts +2 -0
  39. package/dist/types/AvatarToken/index.d.mts.map +1 -0
  40. package/dist/types/AvatarToken/index.mjs +2 -0
  41. package/dist/types/AvatarToken/index.mjs.map +1 -0
  42. package/dist/types/Text/Text.types.cjs +138 -0
  43. package/dist/types/Text/Text.types.cjs.map +1 -0
  44. package/dist/types/Text/Text.types.d.cts +179 -0
  45. package/dist/types/Text/Text.types.d.cts.map +1 -0
  46. package/dist/types/Text/Text.types.d.mts +179 -0
  47. package/dist/types/Text/Text.types.d.mts.map +1 -0
  48. package/dist/types/Text/Text.types.mjs +135 -0
  49. package/dist/types/Text/Text.types.mjs.map +1 -0
  50. package/dist/types/Text/index.cjs +10 -0
  51. package/dist/types/Text/index.cjs.map +1 -0
  52. package/dist/types/Text/index.d.cts +2 -0
  53. package/dist/types/Text/index.d.cts.map +1 -0
  54. package/dist/types/Text/index.d.mts +2 -0
  55. package/dist/types/Text/index.d.mts.map +1 -0
  56. package/dist/types/Text/index.mjs +2 -0
  57. package/dist/types/Text/index.mjs.map +1 -0
  58. package/package.json +1 -1
@@ -0,0 +1 @@
1
+ {"version":3,"file":"Text.types.mjs","sourceRoot":"","sources":["../../../src/types/Text/Text.types.ts"],"names":[],"mappings":"AAEA;;;GAGG;AACH,MAAM,CAAC,MAAM,UAAU,GAAG;IACxB,mBAAmB;IACnB,IAAI,EAAE,MAAM;IACZ,mBAAmB;IACnB,MAAM,EAAE,QAAQ;IAChB,mBAAmB;IACnB,OAAO,EAA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AAE,oBAAoB;IAClC,yDAAyD;IACzD,gBAAgB,EAAE,wBAAwB;IAC1C,+EAA+E;IAC/E,YAAY,EAAE,oBAAoB;IAClC;;;;OAIG;IACH,iBAAiB,EAAE,0BAA0B;IAC7C,kDAAkD;IAClD,mBAAmB,EAAE,4BAA4B;IACjD,oFAAoF;IACpF,cAAc,EAAE,sBAAsB;IACtC,iFAAiF;IACjF,cAAc,EAAE,sBAAsB;IACtC;;;;OAIG;IACH,mBAAmB,EAAE,4BAA4B;IACjD,4CAA4C;IAC5C,qBAAqB,EAAE,8BAA8B;IACrD,yFAAyF;IACzF,cAAc,EAAE,sBAAsB;IACtC,iFAAiF;IACjF,cAAc,EAAE,sBAAsB;IACtC;;;;OAIG;IACH,mBAAmB,EAAE,4BAA4B;IACjD,2CAA2C;IAC3C,qBAAqB,EAAE,8BAA8B;IACrD,sFAAsF;IACtF,WAAW,EAAE,mBAAmB;IAChC,8EAA8E;IAC9E,WAAW,EAAE,mBAAmB;IAChC,sCAAsC;IACtC,WAAW,EAAE,kBAAkB;IAC/B;;;;OAIG;IACH,OAAO,EAAE,cAAc;CACf,CAAC","sourcesContent":["import type { ReactNode } from 'react';\n\n/**\n * Text - fontWeight (ADR-0003)\n * Semantic values shared across React and React Native platforms.\n */\nexport const FontWeight = {\n /** Weight - 600 */\n Bold: 'bold',\n /** Weight - 500 */\n Medium: 'medium',\n /** Weight - 400 */\n Regular: 'regular',\n} as const;\n\nexport type FontWeight = (typeof FontWeight)[keyof typeof FontWeight];\n\n/**\n * Text - fontStyle (ADR-0003)\n * Semantic values shared across React and React Native platforms.\n */\nexport const FontStyle = {\n Italic: 'italic',\n Normal: 'normal',\n} as const;\n\nexport type FontStyle = (typeof FontStyle)[keyof typeof FontStyle];\n\n/**\n * Text - fontFamily (ADR-0003)\n * Semantic values shared across React and React Native platforms.\n */\nexport const FontFamily = {\n /** Default: Geist */\n Default: 'default',\n /** Accent: MM Sans */\n Accent: 'accent',\n /** Hero: MM Poly */\n Hero: 'hero',\n} as const;\n\nexport type FontFamily = (typeof FontFamily)[keyof typeof FontFamily];\n\n/**\n * Text - variant (ADR-0003)\n * Identical values across React and React Native platforms.\n */\nexport const TextVariant = {\n // Display Sizes\n DisplayLg: 'display-lg',\n DisplayMd: 'display-md',\n\n // Heading Sizes\n HeadingLg: 'heading-lg',\n HeadingMd: 'heading-md',\n HeadingSm: 'heading-sm',\n\n // Body Sizes\n BodyLg: 'body-lg',\n BodyMd: 'body-md',\n BodySm: 'body-sm',\n BodyXs: 'body-xs',\n\n // Special Typography Variants\n PageHeading: 'page-heading',\n SectionHeading: 'section-heading',\n ButtonLabelMd: 'button-label-md',\n ButtonLabelLg: 'button-label-lg',\n AmountDisplayLg: 'amount-display-lg',\n} as const;\n\nexport type TextVariant = (typeof TextVariant)[keyof typeof TextVariant];\n\n/**\n * Text - color (ADR-0003)\n * All text color values shared across React and React Native platforms.\n */\nexport const TextColor = {\n /** For default neutral text. */\n TextDefault: 'text-default',\n /** For softer contrast neutral text */\n TextAlternative: 'text-alternative',\n /** For the softest contrast neutral text (not accessible) */\n TextMuted: 'text-muted',\n /** For elements used on top of overlay/alternative. Used for text, icon or border */\n OverlayInverse: 'text-overlay-inverse',\n /** For interactive, active, and selected semantics. Used for text, background, icon or border */\n PrimaryDefault: 'text-primary-default',\n /** For elements used on top of primary/default. Used for text, icon or border */\n PrimaryInverse: 'text-primary-inverse',\n /** For softer variants of primary text. */\n PrimaryAlternative: 'text-primary-alternative',\n /**\n * For primary text in a hover state.\n *\n * @note On React Native, hover as an interaction state does not exist — use `PrimaryDefaultPressed` instead.\n */\n PrimaryDefaultHover: 'text-primary-default-hover',\n /** For primary text in a pressed state. */\n PrimaryDefaultPressed: 'text-primary-default-pressed',\n /** For the critical alert semantic elements. Used for text, background, icon or border */\n ErrorDefault: 'text-error-default',\n /** For the stronger contrast error semantic elements. */\n ErrorAlternative: 'text-error-alternative',\n /** For elements used on top of error/default. Used for text, icon or border */\n ErrorInverse: 'text-error-inverse',\n /**\n * For critical alert text in a hover state.\n *\n * @note On React Native, hover as an interaction state does not exist — use `ErrorDefaultPressed` instead.\n */\n ErrorDefaultHover: 'text-error-default-hover',\n /** For critical alert text in a pressed state. */\n ErrorDefaultPressed: 'text-error-default-pressed',\n /** For the positive semantic elements. Used for text, background, icon or border */\n SuccessDefault: 'text-success-default',\n /** For elements used on top of success/default. Used for text, icon or border */\n SuccessInverse: 'text-success-inverse',\n /**\n * For positive text in a hover state.\n *\n * @note On React Native, hover as an interaction state does not exist — use `SuccessDefaultPressed` instead.\n */\n SuccessDefaultHover: 'text-success-default-hover',\n /** For positive text in a pressed state. */\n SuccessDefaultPressed: 'text-success-default-pressed',\n /** For the caution alert semantic elements. Used for text, background, icon or border */\n WarningDefault: 'text-warning-default',\n /** For elements used on top of warning/default. Used for text, icon or border */\n WarningInverse: 'text-warning-inverse',\n /**\n * For caution text in a hover state.\n *\n * @note On React Native, hover as an interaction state does not exist — use `WarningDefaultPressed` instead.\n */\n WarningDefaultHover: 'text-warning-default-hover',\n /** For caution text in a pressed state. */\n WarningDefaultPressed: 'text-warning-default-pressed',\n /** For informational read-only elements. Used for text, background, icon or border */\n InfoDefault: 'text-info-default',\n /** For elements used on top of info/default. Used for text, icon or border */\n InfoInverse: 'text-info-inverse',\n /** Make the text color transparent */\n Transparent: 'text-transparent',\n /**\n * Inherit the color of the parent element.\n *\n * @platform web — CSS cascade has no equivalent in React Native; fails silently on mobile.\n */\n Inherit: 'text-inherit',\n} as const;\n\nexport type TextColor = (typeof TextColor)[keyof typeof TextColor];\n\n/**\n * Text component shared props (ADR-0004).\n * Platform-independent props shared across React and React Native.\n */\nexport type TextPropsShared = {\n /**\n * Optional prop to change the font size of the component.\n * Different variants map to specific HTML elements by default.\n *\n * @default TextVariant.BodyMd\n */\n variant?: TextVariant;\n /**\n * The text content or elements to be rendered within the component.\n */\n children: ReactNode;\n /**\n * Optional prop that sets the color of the text using predefined theme colors.\n *\n * @default TextColor.TextDefault\n */\n color?: TextColor;\n /**\n * Optional prop to control the font weight of the text.\n * Regular: 400\n * Medium: 500\n * Bold: 600\n */\n fontWeight?: FontWeight;\n /**\n * Optional prop to adjust the font family.\n * Default: Geist\n * Accent: MM Sans\n * Hero: MM Poly\n */\n fontFamily?: FontFamily;\n /**\n * Optional prop to control the font style of the text.\n * Options: Normal, Italic\n */\n fontStyle?: FontStyle;\n};\n"]}
@@ -0,0 +1,10 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.TextVariant = exports.TextColor = exports.FontWeight = exports.FontStyle = exports.FontFamily = void 0;
4
+ var Text_types_1 = require("./Text.types.cjs");
5
+ Object.defineProperty(exports, "FontFamily", { enumerable: true, get: function () { return Text_types_1.FontFamily; } });
6
+ Object.defineProperty(exports, "FontStyle", { enumerable: true, get: function () { return Text_types_1.FontStyle; } });
7
+ Object.defineProperty(exports, "FontWeight", { enumerable: true, get: function () { return Text_types_1.FontWeight; } });
8
+ Object.defineProperty(exports, "TextColor", { enumerable: true, get: function () { return Text_types_1.TextColor; } });
9
+ Object.defineProperty(exports, "TextVariant", { enumerable: true, get: function () { return Text_types_1.TextVariant; } });
10
+ //# sourceMappingURL=index.cjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.cjs","sourceRoot":"","sources":["../../../src/types/Text/index.ts"],"names":[],"mappings":";;;AAAA,+CAOsB;AANpB,wGAAA,UAAU,OAAA;AACV,uGAAA,SAAS,OAAA;AACT,wGAAA,UAAU,OAAA;AACV,uGAAA,SAAS,OAAA;AACT,yGAAA,WAAW,OAAA","sourcesContent":["export {\n FontFamily,\n FontStyle,\n FontWeight,\n TextColor,\n TextVariant,\n type TextPropsShared,\n} from './Text.types';\n"]}
@@ -0,0 +1,2 @@
1
+ export { FontFamily, FontStyle, FontWeight, TextColor, TextVariant, type TextPropsShared, } from "./Text.types.cjs";
2
+ //# sourceMappingURL=index.d.cts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.cts","sourceRoot":"","sources":["../../../src/types/Text/index.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,UAAU,EACV,SAAS,EACT,UAAU,EACV,SAAS,EACT,WAAW,EACX,KAAK,eAAe,GACrB,yBAAqB"}
@@ -0,0 +1,2 @@
1
+ export { FontFamily, FontStyle, FontWeight, TextColor, TextVariant, type TextPropsShared, } from "./Text.types.mjs";
2
+ //# sourceMappingURL=index.d.mts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.mts","sourceRoot":"","sources":["../../../src/types/Text/index.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,UAAU,EACV,SAAS,EACT,UAAU,EACV,SAAS,EACT,WAAW,EACX,KAAK,eAAe,GACrB,yBAAqB"}
@@ -0,0 +1,2 @@
1
+ export { FontFamily, FontStyle, FontWeight, TextColor, TextVariant } from "./Text.types.mjs";
2
+ //# sourceMappingURL=index.mjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.mjs","sourceRoot":"","sources":["../../../src/types/Text/index.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,UAAU,EACV,SAAS,EACT,UAAU,EACV,SAAS,EACT,WAAW,EAEZ,yBAAqB","sourcesContent":["export {\n FontFamily,\n FontStyle,\n FontWeight,\n TextColor,\n TextVariant,\n type TextPropsShared,\n} from './Text.types';\n"]}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@metamask-previews/design-system-shared",
3
- "version": "0.6.0-preview.dbe1fac",
3
+ "version": "0.7.0-preview.4ce710b",
4
4
  "description": "Shared types for design system libraries",
5
5
  "keywords": [
6
6
  "MetaMask",