@kth/style 0.0.10 → 0.0.12

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.
@@ -23,6 +23,8 @@ interface OptionProps {
23
23
  value: string;
24
24
  /** Human-readable label for the option */
25
25
  children: string;
26
+ /** True if the option should be disabled */
27
+ disabled?: boolean;
26
28
  }
27
29
  interface OptionGroupProps {
28
30
  label: string;
@@ -30,5 +32,5 @@ interface OptionGroupProps {
30
32
  }
31
33
  export declare function Select({ name, label, description, value, onChange, children, error, }: SelectProps): JSX.Element;
32
34
  export declare function OptionGroup({ label, children }: OptionGroupProps): JSX.Element;
33
- export declare function Option({ value, children }: OptionProps): JSX.Element;
35
+ export declare function Option({ value, children, disabled }: OptionProps): JSX.Element;
34
36
  export {};
package/dist/cjs/index.js CHANGED
@@ -137,8 +137,8 @@ function Select({ name, label, description, value, onChange, children, error, })
137
137
  function OptionGroup({ label, children }) {
138
138
  return React.createElement("optgroup", { label: label }, children);
139
139
  }
140
- function Option({ value, children }) {
141
- return React.createElement("option", { value: value }, children);
140
+ function Option({ value, children, disabled }) {
141
+ return (React.createElement("option", { value: value, disabled: disabled }, children));
142
142
  }
143
143
 
144
144
  const SvgArrowBack = (props) => (React__namespace.createElement("svg", { xmlns: "http://www.w3.org/2000/svg", width: "1.25em", height: "1.25em", viewBox: "0 0 20 20", ...props },
@@ -23,6 +23,8 @@ interface OptionProps {
23
23
  value: string;
24
24
  /** Human-readable label for the option */
25
25
  children: string;
26
+ /** True if the option should be disabled */
27
+ disabled?: boolean;
26
28
  }
27
29
  interface OptionGroupProps {
28
30
  label: string;
@@ -30,5 +32,5 @@ interface OptionGroupProps {
30
32
  }
31
33
  export declare function Select({ name, label, description, value, onChange, children, error, }: SelectProps): JSX.Element;
32
34
  export declare function OptionGroup({ label, children }: OptionGroupProps): JSX.Element;
33
- export declare function Option({ value, children }: OptionProps): JSX.Element;
35
+ export declare function Option({ value, children, disabled }: OptionProps): JSX.Element;
34
36
  export {};
package/dist/esm/index.js CHANGED
@@ -117,8 +117,8 @@ function Select({ name, label, description, value, onChange, children, error, })
117
117
  function OptionGroup({ label, children }) {
118
118
  return React__default.createElement("optgroup", { label: label }, children);
119
119
  }
120
- function Option({ value, children }) {
121
- return React__default.createElement("option", { value: value }, children);
120
+ function Option({ value, children, disabled }) {
121
+ return (React__default.createElement("option", { value: value, disabled: disabled }, children));
122
122
  }
123
123
 
124
124
  const SvgArrowBack = (props) => (React.createElement("svg", { xmlns: "http://www.w3.org/2000/svg", width: "1.25em", height: "1.25em", viewBox: "0 0 20 20", ...props },
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@kth/style",
3
- "version": "0.0.10",
3
+ "version": "0.0.12",
4
4
  "main": "dist/cjs/index.js",
5
5
  "module": "dist/esm/index.js",
6
6
  "scripts": {
@@ -47,5 +47,5 @@
47
47
  "peerDependencies": {
48
48
  "react": "*"
49
49
  },
50
- "gitHead": "01c4ee2c400d90bf6e9fcf61eec4a0a086aac49d"
50
+ "gitHead": "6774939491027282851d19e5ae9022183f98cfe5"
51
51
  }