@hitachivantara/uikit-react-core 5.73.0 → 5.73.2

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.
@@ -3,7 +3,7 @@ Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
3
3
  const uikitReactUtils = require("@hitachivantara/uikit-react-utils");
4
4
  const uikitStyles = require("@hitachivantara/uikit-styles");
5
5
  const labelBaseStyle = {
6
- ...uikitStyles.theme.typography.label,
6
+ ...uikitStyles.theme.typography.caption2,
7
7
  padding: "0 5px",
8
8
  color: uikitStyles.theme.colors.atmo1,
9
9
  lineHeight: "16px"
@@ -1,7 +1,7 @@
1
1
  import { createClasses } from "@hitachivantara/uikit-react-utils";
2
2
  import { theme } from "@hitachivantara/uikit-styles";
3
3
  const labelBaseStyle = {
4
- ...theme.typography.label,
4
+ ...theme.typography.caption2,
5
5
  padding: "0 5px",
6
6
  color: theme.colors.atmo1,
7
7
  lineHeight: "16px"
@@ -1 +1 @@
1
- {"version":3,"file":"Badge.styles.js","sources":["../../../src/Badge/Badge.styles.tsx"],"sourcesContent":["import { createClasses } from \"@hitachivantara/uikit-react-utils\";\nimport { theme } from \"@hitachivantara/uikit-styles\";\n\nconst labelBaseStyle: React.CSSProperties = {\n ...theme.typography.label,\n padding: \"0 5px\",\n color: theme.colors.atmo1,\n lineHeight: \"16px\",\n};\n\nexport const { staticClasses, useClasses } = createClasses(\"HvBadge\", {\n root: { position: \"relative\", \"&>*\": { float: \"left\" } },\n badgeContainer: { width: 0 },\n badgePosition: {},\n badge: {\n borderRadius: theme.space.xs,\n backgroundColor: theme.colors.secondary,\n float: \"left\",\n minHeight: \"8px\",\n minWidth: \"8px\",\n },\n showCount: { ...labelBaseStyle, wordBreak: \"keep-all\" },\n showLabel: { ...labelBaseStyle, wordBreak: \"keep-all\" },\n badgeIcon: { position: \"relative\", top: \"1px\", left: \"-7px\" },\n badgeOneDigit: { padding: 0, width: \"16px\", textAlign: \"center\" },\n});\n"],"names":[],"mappings":";;AAGA,MAAM,iBAAsC;AAAA,EAC1C,GAAG,MAAM,WAAW;AAAA,EACpB,SAAS;AAAA,EACT,OAAO,MAAM,OAAO;AAAA,EACpB,YAAY;AACd;AAEO,MAAM,EAAE,eAAe,eAAe,cAAc,WAAW;AAAA,EACpE,MAAM,EAAE,UAAU,YAAY,OAAO,EAAE,OAAO,SAAS;AAAA,EACvD,gBAAgB,EAAE,OAAO,EAAE;AAAA,EAC3B,eAAe,CAAC;AAAA,EAChB,OAAO;AAAA,IACL,cAAc,MAAM,MAAM;AAAA,IAC1B,iBAAiB,MAAM,OAAO;AAAA,IAC9B,OAAO;AAAA,IACP,WAAW;AAAA,IACX,UAAU;AAAA,EACZ;AAAA,EACA,WAAW,EAAE,GAAG,gBAAgB,WAAW,WAAW;AAAA,EACtD,WAAW,EAAE,GAAG,gBAAgB,WAAW,WAAW;AAAA,EACtD,WAAW,EAAE,UAAU,YAAY,KAAK,OAAO,MAAM,OAAO;AAAA,EAC5D,eAAe,EAAE,SAAS,GAAG,OAAO,QAAQ,WAAW,SAAS;AAClE,CAAC;"}
1
+ {"version":3,"file":"Badge.styles.js","sources":["../../../src/Badge/Badge.styles.tsx"],"sourcesContent":["import { createClasses } from \"@hitachivantara/uikit-react-utils\";\nimport { theme } from \"@hitachivantara/uikit-styles\";\n\nconst labelBaseStyle: React.CSSProperties = {\n ...theme.typography.caption2,\n padding: \"0 5px\",\n color: theme.colors.atmo1,\n lineHeight: \"16px\",\n};\n\nexport const { staticClasses, useClasses } = createClasses(\"HvBadge\", {\n root: { position: \"relative\", \"&>*\": { float: \"left\" } },\n badgeContainer: { width: 0 },\n badgePosition: {},\n badge: {\n borderRadius: theme.space.xs,\n backgroundColor: theme.colors.secondary,\n float: \"left\",\n minHeight: \"8px\",\n minWidth: \"8px\",\n },\n showCount: { ...labelBaseStyle, wordBreak: \"keep-all\" },\n showLabel: { ...labelBaseStyle, wordBreak: \"keep-all\" },\n badgeIcon: { position: \"relative\", top: \"1px\", left: \"-7px\" },\n badgeOneDigit: { padding: 0, width: \"16px\", textAlign: \"center\" },\n});\n"],"names":[],"mappings":";;AAGA,MAAM,iBAAsC;AAAA,EAC1C,GAAG,MAAM,WAAW;AAAA,EACpB,SAAS;AAAA,EACT,OAAO,MAAM,OAAO;AAAA,EACpB,YAAY;AACd;AAEO,MAAM,EAAE,eAAe,eAAe,cAAc,WAAW;AAAA,EACpE,MAAM,EAAE,UAAU,YAAY,OAAO,EAAE,OAAO,SAAS;AAAA,EACvD,gBAAgB,EAAE,OAAO,EAAE;AAAA,EAC3B,eAAe,CAAC;AAAA,EAChB,OAAO;AAAA,IACL,cAAc,MAAM,MAAM;AAAA,IAC1B,iBAAiB,MAAM,OAAO;AAAA,IAC9B,OAAO;AAAA,IACP,WAAW;AAAA,IACX,UAAU;AAAA,EACZ;AAAA,EACA,WAAW,EAAE,GAAG,gBAAgB,WAAW,WAAW;AAAA,EACtD,WAAW,EAAE,GAAG,gBAAgB,WAAW,WAAW;AAAA,EACtD,WAAW,EAAE,UAAU,YAAY,KAAK,OAAO,MAAM,OAAO;AAAA,EAC5D,eAAe,EAAE,SAAS,GAAG,OAAO,QAAQ,WAAW,SAAS;AAClE,CAAC;"}
@@ -1 +1 @@
1
- {"version":3,"file":"generic.js","sources":["../../../src/types/generic.ts"],"sourcesContent":["import { forwardRef } from \"react\";\nimport type {\n HvExtraDeepProps,\n HvExtraProps,\n} from \"@hitachivantara/uikit-react-shared\";\n\nexport type { HvExtraProps, HvExtraDeepProps };\n\ntype AsProp<C extends React.ElementType> = {\n /** Custom element type to override the root component */\n component?: C;\n};\n\ntype PropsToOmit<C extends React.ElementType, P> = keyof (AsProp<C> & P);\n\n// Workaround to fix the use of Omit with ComponentPropsWithoutRef\n// Without this the event handlers return any instead of the type for the chosen element\ntype FixComponentProps<T> = T extends any ? T : never;\n\ntype PolymorphicComponent<\n C extends React.ElementType,\n Props = {},\n> = React.PropsWithChildren<Props & AsProp<C>> &\n FixComponentProps<\n Omit<React.ComponentPropsWithoutRef<C>, PropsToOmit<C, Props>>\n >;\n\nexport type PolymorphicRef<C extends React.ElementType> =\n React.ComponentPropsWithRef<C>[\"ref\"];\n\nexport type PolymorphicComponentRef<\n C extends React.ElementType,\n Props = {},\n> = PolymorphicComponent<C, Props> & { ref?: PolymorphicRef<C> };\n\n/** HV Base Props. Extends `React.HTMLAttributes` of an element `E`, and filters `K` keys. */\nexport type HvBaseProps<\n E extends HTMLElement = HTMLDivElement,\n K extends keyof React.HTMLAttributes<E> = never,\n> = Omit<React.HTMLAttributes<E>, K>;\n\n/** This type allows to do a deep partial by applying the Partial type to each key recursively */\nexport type DeepPartial<T> = T extends {}\n ? Partial<{\n [P in keyof T]: DeepPartial<T[P]>;\n }>\n : T;\n\n/** This type extends DeepPartial to allow any extra properties */\nexport type HvExtraDeepPartialProps<T> = Partial<{\n [P in keyof T]: DeepPartial<T[P]> & Record<string, any>;\n}> &\n Record<string, any>;\n\nexport type Arrayable<T> = T | T[];\n\n/** React.forwardRef with fixed type declarations */\nexport function fixedForwardRef<T, P = {}>(\n // TODO: change `React.ReactElement | null` to `React.ReactNode` in v6 (requires ts@5+)\n render: (props: P, ref: React.Ref<T>) => React.ReactElement | null,\n): (props: P & React.RefAttributes<T>) => React.ReactElement | null {\n return forwardRef(render) as any;\n}\n\n// Source code from: https://github.com/piotrwitek/utility-types/blob/master/src/mapped-types.ts\n/**\n * Optional\n * @desc From `T` make a set of properties by key `K` become optional\n * @example\n * type Props = {\n * name: string;\n * age: number;\n * visible: boolean;\n * };\n *\n * // Expect: { name?: string; age?: number; visible?: boolean; }\n * type Props = Optional<Props>;\n *\n * // Expect: { name: string; age?: number; visible?: boolean; }\n * type Props = Optional<Props, 'age' | 'visible'>;\n */\nexport type HvOptional<T extends object, K extends keyof T = keyof T> = Omit<\n T,\n K\n> &\n Partial<Pick<T, K>>;\n"],"names":[],"mappings":";AAyDO,SAAS,gBAEd,QACkE;AAClE,SAAO,WAAW,MAAM;AAC1B;"}
1
+ {"version":3,"file":"generic.js","sources":["../../../src/types/generic.ts"],"sourcesContent":["import { forwardRef } from \"react\";\nimport type {\n HvExtraDeepProps,\n HvExtraProps,\n} from \"@hitachivantara/uikit-react-shared\";\n\nexport type { HvExtraProps, HvExtraDeepProps };\n\ntype AsProp<C extends React.ElementType> = {\n /** Custom element type to override the root component */\n component?: C;\n};\n\ntype PropsToOmit<C extends React.ElementType, P> = keyof (AsProp<C> & P);\n\n// Workaround to fix the use of Omit with ComponentPropsWithoutRef\n// Without this the event handlers return any instead of the type for the chosen element\ntype FixComponentProps<T> = T extends any ? T : never;\n\ntype PolymorphicComponent<\n C extends React.ElementType,\n Props = {},\n> = React.PropsWithChildren<Props & AsProp<C>> &\n FixComponentProps<\n Omit<React.ComponentPropsWithoutRef<C>, PropsToOmit<C, Props>>\n >;\n\nexport type PolymorphicRef<C extends React.ElementType> =\n React.ComponentPropsWithRef<C>[\"ref\"];\n\nexport type PolymorphicComponentRef<\n C extends React.ElementType,\n Props = {},\n> = PolymorphicComponent<C, Props> & { ref?: PolymorphicRef<C> };\n\n/** HV Base Props. Extends `React.HTMLAttributes` of an element `E`, and filters `K` keys. */\nexport type HvBaseProps<\n E extends HTMLElement = HTMLDivElement,\n K extends keyof React.HTMLAttributes<E> = never,\n> = Omit<React.HTMLAttributes<E>, K>;\n\n/** This type allows to do a deep partial by applying the Partial type to each key recursively */\nexport type DeepPartial<T> = T extends {}\n ? Partial<{\n [P in keyof T]: DeepPartial<T[P]>;\n }>\n : T;\n\n/** This type extends DeepPartial to allow any extra properties */\nexport type HvExtraDeepPartialProps<T> = Partial<{\n [P in keyof T]: DeepPartial<T[P]> & Record<string, any>;\n}> &\n Record<string, any>;\n\nexport type Arrayable<T> = T | T[];\n\n/** React.forwardRef with fixed type declarations */\nexport function fixedForwardRef<T, P = {}>(\n // TODO: change `React.ReactElement | null` to `React.ReactNode` in v6 (requires ts@5+)\n render: (props: P, ref: React.Ref<T>) => React.ReactElement | null,\n): (props: P & React.RefAttributes<T>) => React.ReactElement | null {\n // https://github.com/DefinitelyTyped/DefinitelyTyped/pull/70361#issuecomment-2327456092\n return forwardRef(render as any) as any;\n}\n\n// Source code from: https://github.com/piotrwitek/utility-types/blob/master/src/mapped-types.ts\n/**\n * Optional\n * @desc From `T` make a set of properties by key `K` become optional\n * @example\n * type Props = {\n * name: string;\n * age: number;\n * visible: boolean;\n * };\n *\n * // Expect: { name?: string; age?: number; visible?: boolean; }\n * type Props = Optional<Props>;\n *\n * // Expect: { name: string; age?: number; visible?: boolean; }\n * type Props = Optional<Props, 'age' | 'visible'>;\n */\nexport type HvOptional<T extends object, K extends keyof T = keyof T> = Omit<\n T,\n K\n> &\n Partial<Pick<T, K>>;\n"],"names":[],"mappings":";AAyDO,SAAS,gBAEd,QACkE;AAElE,SAAO,WAAW,MAAa;AACjC;"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@hitachivantara/uikit-react-core",
3
- "version": "5.73.0",
3
+ "version": "5.73.2",
4
4
  "private": false,
5
5
  "author": "Hitachi Vantara UI Kit Team",
6
6
  "description": "Core React components for the NEXT Design System.",
@@ -32,10 +32,10 @@
32
32
  "dependencies": {
33
33
  "@emotion/cache": "^11.11.0",
34
34
  "@emotion/serialize": "^1.1.2",
35
- "@hitachivantara/uikit-react-icons": "^5.12.0",
36
- "@hitachivantara/uikit-react-shared": "^5.3.5",
37
- "@hitachivantara/uikit-react-utils": "^0.2.5",
38
- "@hitachivantara/uikit-styles": "^5.34.0",
35
+ "@hitachivantara/uikit-react-icons": "^5.12.1",
36
+ "@hitachivantara/uikit-react-shared": "^5.3.6",
37
+ "@hitachivantara/uikit-react-utils": "^0.2.6",
38
+ "@hitachivantara/uikit-styles": "^5.34.1",
39
39
  "@internationalized/date": "^3.2.0",
40
40
  "@mui/base": "^5.0.0-beta.40",
41
41
  "@popperjs/core": "^2.11.8",
@@ -62,7 +62,7 @@
62
62
  "access": "public",
63
63
  "directory": "package"
64
64
  },
65
- "gitHead": "28985d0931d61161910d73f3eb2b1d312ec86a81",
65
+ "gitHead": "a3f960a4d21b27d7d7f471cffe09922ccedeef07",
66
66
  "exports": {
67
67
  ".": {
68
68
  "types": "./dist/types/index.d.ts",