@primer/styled-react 0.0.0-20251003033101 → 0.0.0-20251003034803

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.
@@ -1,18 +1,13 @@
1
- import { FormControl as PrimerFormControl, type FormControlProps as PrimerFormControlProps, type FormControlCaptionProps as PrimerFormControlCaptionProps, type FormControlValidationProps as PrimerFormControlValidationProps, type SxProp } from '@primer/react';
1
+ import { FormControl as PrimerFormControl, type FormControlProps as PrimerFormControlProps, type SxProp } from '@primer/react';
2
2
  import { type PropsWithChildren } from 'react';
3
3
  type FormControlProps = PropsWithChildren<PrimerFormControlProps> & SxProp;
4
4
  declare const FormControlImpl: import("react").ForwardRefExoticComponent<PrimerFormControlProps & {
5
5
  children?: import("react").ReactNode | undefined;
6
6
  } & SxProp & import("react").RefAttributes<HTMLDivElement>>;
7
- type FormControlCaptionProps = PropsWithChildren<PrimerFormControlCaptionProps> & SxProp;
8
- declare const FormControlCaption: (props: FormControlCaptionProps) => import("react").JSX.Element;
9
- type FormControlValidationProps = PropsWithChildren<PrimerFormControlValidationProps> & SxProp;
10
- declare const FormControlValidation: (props: FormControlValidationProps) => import("react").JSX.Element;
11
- declare const FormControlLeadingVisual: (props: PropsWithChildren<SxProp>) => import("react").JSX.Element;
12
7
  declare const FormControl: typeof FormControlImpl & {
13
- Caption: typeof FormControlCaption;
14
- LeadingVisual: typeof FormControlLeadingVisual;
15
- Validation: typeof FormControlValidation;
8
+ Caption: typeof PrimerFormControl.Caption;
9
+ LeadingVisual: typeof PrimerFormControl.LeadingVisual;
10
+ Validation: typeof PrimerFormControl.Validation;
16
11
  Label: typeof PrimerFormControl.Label;
17
12
  };
18
13
  export { FormControl, type FormControlProps };
@@ -1 +1 @@
1
- {"version":3,"file":"FormControl.d.ts","sourceRoot":"","sources":["../../src/components/FormControl.tsx"],"names":[],"mappings":"AAAA,OAAO,EAEL,WAAW,IAAI,iBAAiB,EAChC,KAAK,gBAAgB,IAAI,sBA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G,MAAM,CAAA;AAE1E,QAAA,MAAM,eAAe;;2DAEnB,CAAA;AAEF,QAAA,MAAM,WAAW,EAKX,OAAO,eAAe,GAAG;IAC7B,OAAO,EAAE,OAAO,iBAAiB,CAAC,OAAO,CAAA;IACzC,aAAa,EAAE,OAAO,iBAAiB,CAAC,aAAa,CAAA;IACrD,UAAU,EAAE,OAAO,iBAAiB,CAAC,UAAU,CAAA;IAC/C,KAAK,EAAE,OAAO,iBAAiB,CAAC,KAAK,CAAA;CACtC,CAAA;AAED,OAAO,EAAC,WAAW,EAAE,KAAK,gBAAgB,EAAC,CAAA"}
@@ -1,5 +1,5 @@
1
1
  import React, { type PropsWithChildren } from 'react';
2
- import type { PageLayoutProps as PrimerPageLayoutProps, PageLayoutContentProps as PrimerPageLayoutContentProps, PageLayoutHeaderProps as PrimerPageLayoutHeaderProps, PageLayoutPaneProps as PrimerPageLayoutPaneProps, PageLayoutFooterProps as PrimerPageLayoutFooterProps } from '@primer/react';
2
+ import type { PageLayoutProps as PrimerPageLayoutProps, PageLayoutContentProps as PrimerPageLayoutContentProps, PageLayoutPaneProps as PrimerPageLayoutPaneProps } from '@primer/react';
3
3
  import { type SxProp } from '../sx';
4
4
  type PageLayoutProps = PropsWithChildren<PrimerPageLayoutProps> & SxProp;
5
5
  declare const PageLayout: React.ForwardRefExoticComponent<PrimerPageLayoutProps & {
@@ -8,15 +8,11 @@ declare const PageLayout: React.ForwardRefExoticComponent<PrimerPageLayoutProps
8
8
  Content: React.ForwardRefExoticComponent<PrimerPageLayoutContentProps & {
9
9
  children?: React.ReactNode | undefined;
10
10
  } & SxProp & React.RefAttributes<HTMLDivElement>>;
11
- Header: React.ForwardRefExoticComponent<PrimerPageLayoutHeaderProps & {
12
- children?: React.ReactNode | undefined;
13
- } & SxProp & React.RefAttributes<HTMLDivElement>>;
11
+ Header: React.FC<React.PropsWithChildren<import("@primer/react").PageLayoutHeaderProps>>;
14
12
  Pane: React.ForwardRefExoticComponent<PrimerPageLayoutPaneProps & {
15
13
  children?: React.ReactNode | undefined;
16
14
  } & SxProp & React.RefAttributes<HTMLDivElement>>;
17
- Footer: React.ForwardRefExoticComponent<PrimerPageLayoutFooterProps & {
18
- children?: React.ReactNode | undefined;
19
- } & SxProp & React.RefAttributes<HTMLDivElement>>;
15
+ Footer: React.FC<React.PropsWithChildren<import("@primer/react").PageLayoutFooterProps>>;
20
16
  };
21
17
  export { PageLayout, type PageLayoutProps };
22
18
  //# sourceMappingURL=PageLayout.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"PageLayout.d.ts","sourceRoot":"","sources":["../../src/components/PageLayout.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,EAAC,KAAK,iBAAiB,EAAC,MAAM,OAAO,CAAA;AAEnD,OAAO,KAAK,EACV,eAAe,IAAI,qBAAqB,EACxC,sBAAsB,IAAI,4BAA4B,EACtD,qBAAqB,IAAI,2BAA2B,EACpD,mBAAmB,IAAI,yBAAyB,EAChD,qBAAqB,IAAI,2BAA2B,EACrD,MAAM,eAAe,CAAA;AAEtB,OAAO,EAAK,KAAK,MAAM,EAAC,MAAM,OAAO,CAAA;AAMrC,KAAK,eAAe,GAAG,iBAAiB,CAAC,qBAAqB,CAAC,GAAG,MAAM,CAAA;AAiCxE,QAAA,MAAM,UAAU;;;;;;;;;;;;;;;CAKd,CAAA;AAEF,OAAO,EAAC,UAAU,EAAE,KAAK,eAAe,EAAC,CAAA"}
1
+ {"version":3,"file":"PageLayout.d.ts","sourceRoot":"","sources":["../../src/components/PageLayout.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,EAAC,KAAK,iBAAiB,EAAC,MAAM,OAAO,CAAA;AAEnD,OAAO,KAAK,EACV,eAAe,IAAI,qBAAqB,EACxC,sBAAsB,IAAI,4BAA4B,EACtD,mBAAmB,IAAI,yBAAyB,EACjD,MAAM,eAAe,CAAA;AAEtB,OAAO,EAAK,KAAK,MAAM,EAAC,MAAM,OAAO,CAAA;AAMrC,KAAK,eAAe,GAAG,iBAAiB,CAAC,qBAAqB,CAAC,GAAG,MAAM,CAAA;AAmBxE,QAAA,MAAM,UAAU;;;;;;;;;;;CAKd,CAAA;AAEF,OAAO,EAAC,UAAU,EAAE,KAAK,eAAe,EAAC,CAAA"}
package/dist/index.js CHANGED
@@ -144,28 +144,10 @@ const FormControlImpl = /*#__PURE__*/forwardRef(function FormControl(props, ref)
144
144
  ...props
145
145
  });
146
146
  });
147
- const FormControlCaption = props => {
148
- return /*#__PURE__*/jsx(Box, {
149
- as: FormControl$1.Caption,
150
- ...props
151
- });
152
- };
153
- const FormControlValidation = props => {
154
- return /*#__PURE__*/jsx(Box, {
155
- as: FormControl$1.Validation,
156
- ...props
157
- });
158
- };
159
- const FormControlLeadingVisual = props => {
160
- return /*#__PURE__*/jsx(Box, {
161
- as: FormControl$1.LeadingVisual,
162
- ...props
163
- });
164
- };
165
147
  const FormControl = Object.assign(FormControlImpl, {
166
- Caption: FormControlCaption,
167
- LeadingVisual: FormControlLeadingVisual,
168
- Validation: FormControlValidation,
148
+ Caption: FormControl$1.Caption,
149
+ LeadingVisual: FormControl$1.LeadingVisual,
150
+ Validation: FormControl$1.Validation,
169
151
  Label: FormControl$1.Label
170
152
  });
171
153
 
@@ -332,14 +314,6 @@ const PageLayoutContent = /*#__PURE__*/React.forwardRef((props, ref) => {
332
314
  ...props
333
315
  });
334
316
  });
335
- const PageLayoutHeader = /*#__PURE__*/React.forwardRef((props, ref) => {
336
- // @ts-expect-error - PrimerPageLayout.Header is not recognized as a valid component type
337
- return /*#__PURE__*/jsx(Wrapper, {
338
- as: PageLayout$1.Header,
339
- ref: ref,
340
- ...props
341
- });
342
- });
343
317
  const PageLayoutPane = /*#__PURE__*/React.forwardRef((props, ref) => {
344
318
  return /*#__PURE__*/jsx(Wrapper, {
345
319
  as: PageLayout$1.Pane,
@@ -347,19 +321,11 @@ const PageLayoutPane = /*#__PURE__*/React.forwardRef((props, ref) => {
347
321
  ...props
348
322
  });
349
323
  });
350
- const PageLayoutFooter = /*#__PURE__*/React.forwardRef((props, ref) => {
351
- // @ts-expect-error - PrimerPageLayout.Footer is not recognized as a valid component type
352
- return /*#__PURE__*/jsx(Wrapper, {
353
- as: PageLayout$1.Footer,
354
- ref: ref,
355
- ...props
356
- });
357
- });
358
324
  const PageLayout = Object.assign(PageLayoutImpl, {
359
325
  Content: PageLayoutContent,
360
- Header: PageLayoutHeader,
326
+ Header: PageLayout$1.Header,
361
327
  Pane: PageLayoutPane,
362
- Footer: PageLayoutFooter
328
+ Footer: PageLayout$1.Footer
363
329
  });
364
330
 
365
331
  const RadioGroupImpl = props => {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@primer/styled-react",
3
- "version": "0.0.0-20251003033101",
3
+ "version": "0.0.0-20251003034803",
4
4
  "type": "module",
5
5
  "exports": {
6
6
  ".": {
@@ -30,7 +30,7 @@
30
30
  "devDependencies": {
31
31
  "@babel/preset-react": "^7.27.1",
32
32
  "@babel/preset-typescript": "^7.27.1",
33
- "@primer/react": "0.0.0-20251003033101",
33
+ "@primer/react": "0.0.0-20251003034803",
34
34
  "@rollup/plugin-babel": "^6.0.4",
35
35
  "@types/react": "18.3.11",
36
36
  "@types/react-dom": "18.3.1",
@@ -46,7 +46,7 @@
46
46
  "typescript": "^5.9.2"
47
47
  },
48
48
  "peerDependencies": {
49
- "@primer/react": "0.0.0-20251003033101",
49
+ "@primer/react": "0.0.0-20251003034803",
50
50
  "@types/react": "18.x || 19.x",
51
51
  "@types/react-dom": "18.x || 19.x",
52
52
  "@types/react-is": "18.x || 19.x",