@genesislcap/rapid-design-system 15.3.5 → 15.4.1

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,4 +1,23 @@
1
1
  import { ElementStyles } from '@microsoft/fast-element';
2
2
  import type { ElementDefinitionContext, FoundationElementDefinition } from '@microsoft/fast-foundation';
3
3
  export declare const rapidButtonStyles: (context: ElementDefinitionContext, definition: FoundationElementDefinition) => ElementStyles;
4
+ /**
5
+ * Every `appearance` value rapid-design-system actually styles.
6
+ *
7
+ * Derived from this file: the `appearanceBehavior(...)` registrations above plus the
8
+ * `:host([appearance='accent'])` rule — keep it in step with them.
9
+ *
10
+ * WHY IT IS DECLARED HERE RATHER THAN ON THE COMPONENT. `Button extends FoundationButton extends
11
+ * FASTButton`, and FAST declares `appearance: ButtonAppearance` = 'accent' | 'lightweight' |
12
+ * 'neutral' | 'outline' | 'stealth'. TypeScript requires a derived property to be assignable to the
13
+ * base's, so a subclass cannot widen it — `declare appearance: RapidButtonAppearance` gives TS2416
14
+ * and class/interface merging gives TS2415/TS2430. The React wrapper therefore surfaces this type
15
+ * through the `reactWrapperPropTypes` override in package.json (see ts-builder's
16
+ * react-wrapper-generator), which is the only boundary at which the public prop type can be
17
+ * corrected.
18
+ *
19
+ * The FAST-base values are retained so widening stays non-breaking for anything already compiling,
20
+ * but note `lightweight` / `outline` / `stealth` are NOT styled here and render as a plain button.
21
+ */
22
+ export type RapidButtonAppearance = 'accent' | 'lightweight' | 'neutral' | 'outline' | 'stealth' | 'primary' | 'secondary' | 'tertiary' | 'danger' | 'success' | 'warning' | 'primary-outline' | 'secondary-outline' | 'neutral-outline' | 'link';
4
23
  //# sourceMappingURL=button.styles.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"button.styles.d.ts","sourceRoot":"","sources":["../../../src/button/button.styles.ts"],"names":[],"mappings":"AACA,OAAO,EAAO,aAAa,EAAE,MAAM,yBAAyB,CAAC;AAC7D,OAAO,KAAK,EACV,wBAAwB,EACxB,2BAA2B,EAC5B,MAAM,4BAA4B,CAAC;AAyUpC,eAAO,MAAM,iBAAiB,GAC5B,SAAS,wBAAwB,EACjC,YAAY,2BAA2B,KACtC,aAgBA,CAAC"}
1
+ {"version":3,"file":"button.styles.d.ts","sourceRoot":"","sources":["../../../src/button/button.styles.ts"],"names":[],"mappings":"AACA,OAAO,EAAO,aAAa,EAAE,MAAM,yBAAyB,CAAC;AAC7D,OAAO,KAAK,EACV,wBAAwB,EACxB,2BAA2B,EAC5B,MAAM,4BAA4B,CAAC;AAyUpC,eAAO,MAAM,iBAAiB,GAC5B,SAAS,wBAAwB,EACjC,YAAY,2BAA2B,KACtC,aAgBA,CAAC;AAEJ;;;;;;;;;;;;;;;;;GAiBG;AACH,MAAM,MAAM,qBAAqB,GAE7B,QAAQ,GACR,aAAa,GACb,SAAS,GACT,SAAS,GACT,SAAS,GAET,SAAS,GACT,WAAW,GACX,UAAU,GACV,QAAQ,GACR,SAAS,GACT,SAAS,GAET,iBAAiB,GACjB,mBAAmB,GACnB,iBAAiB,GAEjB,MAAM,CAAC"}
@@ -87,6 +87,7 @@ import type { TreeItem as TreeItemWC } from './tree-item/tree-item';
87
87
  import type { TreeView as TreeViewWC } from './tree-view/tree-view';
88
88
  import type { UrlInput as UrlInputWC } from './url-input/url-input';
89
89
  import type { VerificationCodeInput as VerificationCodeInputWC } from './verification-code-input/verification-code-input';
90
+ import type { RapidButtonAppearance } from './button/button.styles';
90
91
  import type { AddGroupEventDetail, AddRuleEventDetail, DelGroupEventDetail, DelRuleEventDetail, UpdateGroupEventDetail, UpdateRuleEventDetail } from '@genesislcap/expression-builder';
91
92
  import type { ClearOptions, FileSelectedEventDetail, FilterChangedEventDetail, FilterClearedEventDetail, MultiselectOption, OpenChangeEventDetail, SelectedOption, StepClickEventDetail, ValidationError, ValidationFailureEventDetail, VerificationCodeInputEventDetail } from '@genesislcap/foundation-ui';
92
93
 
@@ -233,8 +234,9 @@ export type BreadcrumbItemRef = BreadcrumbItemWC;
233
234
 
234
235
  export declare const Button: React.ForwardRefExoticComponent<
235
236
  React.PropsWithChildren<
236
- Omit<PublicOf<ButtonWC>, 'children' | 'style'> &
237
+ Omit<PublicOf<ButtonWC>, 'children' | 'style' | 'appearance'> &
237
238
  HTMLWCProps & {
239
+ appearance?: RapidButtonAppearance;
238
240
  }
239
241
  > & React.RefAttributes<ButtonWC>
240
242
  >;
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@genesislcap/rapid-design-system",
3
3
  "description": "Rapid Design System",
4
- "version": "15.3.5",
4
+ "version": "15.4.1",
5
5
  "sideEffects": false,
6
6
  "license": "SEE LICENSE IN license.txt",
7
7
  "main": "dist/esm/index.js",
@@ -38,13 +38,13 @@
38
38
  },
39
39
  "devDependencies": {
40
40
  "@genesiscommunitysuccess/analyzer-import-alias-plugin": "^5.0.3",
41
- "@genesislcap/foundation-testing": "15.3.5",
42
- "@genesislcap/genx": "15.3.5",
43
- "@genesislcap/rollup-builder": "15.3.5",
44
- "@genesislcap/ts-builder": "15.3.5",
45
- "@genesislcap/uvu-playwright-builder": "15.3.5",
46
- "@genesislcap/vite-builder": "15.3.5",
47
- "@genesislcap/webpack-builder": "15.3.5",
41
+ "@genesislcap/foundation-testing": "15.4.1",
42
+ "@genesislcap/genx": "15.4.1",
43
+ "@genesislcap/rollup-builder": "15.4.1",
44
+ "@genesislcap/ts-builder": "15.4.1",
45
+ "@genesislcap/uvu-playwright-builder": "15.4.1",
46
+ "@genesislcap/vite-builder": "15.4.1",
47
+ "@genesislcap/webpack-builder": "15.4.1",
48
48
  "flexlayout-react": "^0.8.19"
49
49
  },
50
50
  "peerDependencies": {
@@ -56,9 +56,9 @@
56
56
  }
57
57
  },
58
58
  "dependencies": {
59
- "@genesislcap/foundation-logger": "15.3.5",
60
- "@genesislcap/foundation-ui": "15.3.5",
61
- "@genesislcap/foundation-utils": "15.3.5",
59
+ "@genesislcap/foundation-logger": "15.4.1",
60
+ "@genesislcap/foundation-ui": "15.4.1",
61
+ "@genesislcap/foundation-utils": "15.4.1",
62
62
  "@microsoft/fast-colors": "5.3.1",
63
63
  "@microsoft/fast-components": "2.30.6",
64
64
  "@microsoft/fast-element": "1.14.0",
@@ -75,6 +75,14 @@
75
75
  "access": "public"
76
76
  },
77
77
  "customElements": "dist/custom-elements.json",
78
+ "reactWrapperPropTypes": {
79
+ "Button": {
80
+ "appearance": {
81
+ "type": "RapidButtonAppearance",
82
+ "from": "./button/button.styles"
83
+ }
84
+ }
85
+ },
78
86
  "exports": {
79
87
  ".": {
80
88
  "types": "./dist/dts/index.d.ts",
@@ -86,5 +94,5 @@
86
94
  "require": "./dist/react.cjs"
87
95
  }
88
96
  },
89
- "gitHead": "dc772a3a6f1b3d1c249f1ffae27a13d29878609c"
97
+ "gitHead": "984a77280362d69ba3eab6256dbb7fe03b8c76b3"
90
98
  }