@sproutsocial/racine 11.7.0-input-beta.4 → 11.8.0

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.
package/CHANGELOG.md CHANGED
@@ -1,5 +1,30 @@
1
1
  # Change Log
2
2
 
3
+ ## 11.8.0
4
+
5
+ ### Minor Changes
6
+
7
+ - 1b66f38: Input.ClearButton no longer requires onClear prop
8
+ - Input has been updated to be able to clear itself for both controlled and uncontrolled Inputs
9
+ - The onChange function will be called upon clearing the input.
10
+ - Due to this change, Inputs with type "search" will now automatically include a ClearButton, whereas previously a ClearButton would not be rendered unless an onClear prop was provided.
11
+
12
+ ### Patch Changes
13
+
14
+ - 1b66f38: Adjust Input elemBefore and elemAfter positioning
15
+ - These elements were previously positioned 12px from the side of the Input
16
+ - They are now positioned 8px from the side of the Input, for better alignment with Input.ClearButton.
17
+ - 1b66f38: Expose Input.ClearButton for uncontrolled Inputs
18
+ - Previously, Input.ClearButton would not be usable for uncontrolled Inputs due to checking whether a value was in the input to clear only via the "value" prop.
19
+ - Now, Input.ClearButton is usable for uncontrolled Inputs because it is checking for updates to the value in its handleChange function.
20
+
21
+ ## 11.7.1
22
+
23
+ ### Patch Changes
24
+
25
+ - d7b2b1f: - Plug icon
26
+ - Alternate help icon
27
+
3
28
  ## 11.7.0
4
29
 
5
30
  ### Minor Changes
@@ -182,90 +182,90 @@ const getIcon = (type, color) => {
182
182
 
183
183
  // eslint-disable-next-line prettier/prettier
184
184
  export const CheckboxContainer: StyledComponent<any, TypeTheme, *> = styled.span(
185
- (props) => css`
186
- display: inline-flex;
187
- align-items: center;
188
- box-sizing: border-box;
189
- position: relative;
190
- transition: all ${props.theme.duration.fast} ${props.theme.easing.ease_in};
191
-
192
- @supports (-webkit-appearance: none) {
193
- &:before {
194
- /* stylelint-disable */
195
- content: url("data:image/svg+xml;utf8,${getIcon(
196
- props.indeterminate ? "indeterminate" : "check",
197
-
198
- props.checked
199
- ? props.theme.colors.form.background.base
200
- : props.theme.colors.form.border.base
201
- )}");
202
- opacity: ${props.checked ? 1 : 0};
203
- position: absolute;
204
- width: ${props.theme.space[400]};
205
- height: ${props.theme.space[400]};
206
- text-align: center;
207
- transform: translateY(1px);
208
- line-height: 1;
209
- margin: auto;
210
- pointer-events: none;
211
- transition: ${props.theme.duration.fast}
212
- ${props.theme.easing.ease_inout};
213
- }
214
-
215
- &:hover:before {
216
- opacity: ${props.disabled && !props.checked ? 0 : 1};
217
- }
218
-
219
- ${props.disabled &&
220
- css`
221
- opacity: 0.4;
222
- `}
223
-
224
- input[type='checkbox'] {
225
- box-sizing: border-box;
226
- appearance: none;
227
- margin: 0;
228
- padding: 0;
229
- width: ${props.theme.space[400]};
230
- height: ${props.theme.space[400]};
231
- border: 1px solid ${props.theme.colors.form.border.base};
232
- border-radius: 4px;
233
- background-color: ${props.theme.colors.form.background.base};
234
- transition: all ${props.theme.duration.fast}
235
- ${props.theme.easing.ease_in};
236
- cursor: ${props.disabled ? "not-allowed" : "pointer"};
237
- flex-shrink: 0;
238
-
239
- &:not(:checked) {
240
- ${!props.indeterminate &&
241
- css`
242
- border-color: ${props.theme.colors
243
- .neutral[300]} !important; /* We don't want the focus ring to remove the border */
244
- background-color: ${props.theme.colors.form.background.base};
245
- `}
185
+ (props) => css`
186
+ display: inline-flex;
187
+ align-items: center;
188
+ box-sizing: border-box;
189
+ position: relative;
190
+ transition: all ${props.theme.duration.fast} ${props.theme.easing.ease_in};
191
+
192
+ @supports (-webkit-appearance: none) {
193
+ &:before {
194
+ /* stylelint-disable */
195
+ content: url("data:image/svg+xml;utf8,${getIcon(
196
+ props.indeterminate ? "indeterminate" : "check",
197
+
198
+ props.checked
199
+ ? props.theme.colors.form.background.base
200
+ : props.theme.colors.form.border.base
201
+ )}");
202
+ opacity: ${props.checked ? 1 : 0};
203
+ position: absolute;
204
+ width: ${props.theme.space[400]};
205
+ height: ${props.theme.space[400]};
206
+ text-align: center;
207
+ transform: translateY(1px);
208
+ line-height: 1;
209
+ margin: auto;
210
+ pointer-events: none;
211
+ transition: ${props.theme.duration.fast}
212
+ ${props.theme.easing.ease_inout};
246
213
  }
247
214
 
248
- &:checked {
249
- border-color: ${props.theme.colors.form.border.selected};
250
- background-color: ${props.theme.colors.form.background.selected};
215
+ &:hover:before {
216
+ opacity: ${props.disabled && !props.checked ? 0 : 1};
251
217
  }
252
218
 
253
- ${props.indeterminate &&
254
- props.checked &&
219
+ ${props.disabled &&
255
220
  css`
256
- border-color: ${props.theme.colors.form.border.selected} !important;
257
- background-color: ${props.theme.colors.form.background
258
- .selected} !important;
221
+ opacity: 0.4;
259
222
  `}
260
223
 
261
- &:focus {
262
- ${focusRing}
224
+ input[type='checkbox'] {
225
+ box-sizing: border-box;
226
+ appearance: none;
227
+ margin: 0;
228
+ padding: 0;
229
+ width: ${props.theme.space[400]};
230
+ height: ${props.theme.space[400]};
231
+ border: 1px solid ${props.theme.colors.form.border.base};
232
+ border-radius: 4px;
233
+ background-color: ${props.theme.colors.form.background.base};
234
+ transition: all ${props.theme.duration.fast}
235
+ ${props.theme.easing.ease_in};
236
+ cursor: ${props.disabled ? "not-allowed" : "pointer"};
237
+ flex-shrink: 0;
238
+
239
+ &:not(:checked) {
240
+ ${!props.indeterminate &&
241
+ css`
242
+ border-color: ${props.theme.colors
243
+ .neutral[300]} !important; /* We don't want the focus ring to remove the border */
244
+ background-color: ${props.theme.colors.form.background.base};
245
+ `}
246
+ }
247
+
248
+ &:checked {
249
+ border-color: ${props.theme.colors.form.border.selected};
250
+ background-color: ${props.theme.colors.form.background.selected};
251
+ }
252
+
253
+ ${props.indeterminate &&
254
+ props.checked &&
255
+ css`
256
+ border-color: ${props.theme.colors.form.border.selected} !important;
257
+ background-color: ${props.theme.colors.form.background
258
+ .selected} !important;
259
+ `}
260
+
261
+ &:focus {
262
+ ${focusRing}
263
+ }
263
264
  }
264
265
  }
265
- }
266
266
 
267
- ${COMMON}
268
- `
269
- );
267
+ ${COMMON}
268
+ `
269
+ );
270
270
 
271
271
  export default Container;
@@ -73,9 +73,8 @@ const Trigger = ({ children, ...rest }) => {
73
73
  };
74
74
 
75
75
  const Panel = ({ children, ...rest }) => {
76
- const { isOpen, id, offset, collapsedHeight, openHeight } = useContext(
77
- CollapsibleContext
78
- );
76
+ const { isOpen, id, offset, collapsedHeight, openHeight } =
77
+ useContext(CollapsibleContext);
79
78
  const ref = useRef();
80
79
  const measurement = useMeasure(ref);
81
80
  const [isHidden, setIsHidden] = useState(undefined);
@@ -1,2 +1,2 @@
1
1
  // @flow
2
- export type EnumIconNames = "active-listener" | "add-item" | "add-keyword" | "add-team-member" | "add-variable" | "address-card-outline" | "address-card-solid" | "adobe-experience-manager" | "ads" | "android" | "apple" | "approval-indicator-outline" | "approval-indicator" | "archive" | "arrow-down-line" | "arrow-down" | "arrow-left-line" | "arrow-left" | "arrow-right-line" | "arrow-right" | "arrow-up-line" | "arrow-up" | "arrows" | "asset-library-outline" | "asset-library" | "assign" | "atom" | "audio" | "back-to-top" | "bambu-icon-outline" | "bambu-icon" | "barcode" | "basketball" | "bell-outline" | "bigcommerce" | "bitly" | "bold" | "book" | "bot" | "browser" | "business" | "calendar-outline" | "calendar" | "camera-outline" | "camera-story" | "camera" | "campaign" | "canva" | "carousel" | "cart-plus-outline" | "cart-plus" | "check" | "chevron-down-filled" | "chevron-down" | "chevron-left" | "chevron-right" | "chevron-up-down-filled" | "chevron-up-filled" | "chevron-up" | "circle-check-outline" | "circle-check" | "circle" | "circle+" | "circles" | "circlex" | "click-to-view" | "clicks" | "clipboard-outline" | "clipboard" | "clock" | "closed-captioning" | "cloud" | "code" | "columns" | "comment-alt-outline" | "comment-alt" | "comment-lines-alt-outline" | "comment" | "compact-density" | "compact-indicator" | "comparison" | "competitor" | "compose" | "content-suggestions" | "credit-card" | "crop" | "crown" | "dashboard" | "deconstructed-negative-sentiment" | "deconstructed-neutral-sentiment" | "deconstructed-positive-sentiment" | "discovery" | "dislike-outline" | "dislike" | "dm-link-outline" | "dm-link" | "dotdotdot" | "download" | "drafts-outline" | "drafts" | "dropbox" | "duplicate-outline" | "duplicate" | "emoji-outline" | "emoji" | "empty-image" | "engagement-per-post" | "engagements" | "error" | "exchange-alt" | "expanded-indicator" | "export" | "extended-circles" | "external-link-alt" | "external-link" | "extreme-negative-sentiment" | "eye-outline" | "eye-slash-outline" | "eye-slash" | "eye" | "facebook-audience-network" | "facebook-branded-content-outline" | "facebook-branded-content" | "facebook-groups" | "facebook" | "fb-reactions-angry" | "fb-reactions-haha" | "fb-reactions-like" | "fb-reactions-love" | "fb-reactions-sad" | "fb-reactions-wow" | "feedly" | "feeds" | "female" | "file-chart-line" | "file-edit" | "file-times-solid" | "filter" | "flag-outline" | "flag" | "flat-negative-sentiment-outline" | "flat-negative-sentiment" | "flat-neutral-sentiment-outline" | "flat-neutral-sentiment" | "flat-positive-sentiment-outline" | "flat-positive-sentiment" | "folder-open" | "folder" | "follow-outline" | "follow" | "follower-increase" | "following" | "font" | "full-access" | "gear" | "gears" | "glassdoor" | "glasses" | "globe" | "google-analytics-color" | "google-business-messages" | "google-drive" | "google-my-business" | "grip" | "h1" | "h2" | "hamburger" | "hashtag" | "headset" | "heart-outline" | "heart" | "heartbeat" | "help" | "hiking" | "history" | "home" | "hourglass" | "hubspot" | "image-caption" | "image" | "images" | "impressions-per-post" | "impressions" | "inactive-listener" | "inbox-action" | "inbox-views" | "inbox" | "indicator" | "industry" | "info" | "instagram" | "internal-activity-outline" | "internal-activity" | "italic" | "key" | "keyboard" | "laptop-phone" | "large-density" | "lift" | "like-outline" | "like" | "link" | "linkedin-audience-network" | "linkedin" | "list-ol" | "listening" | "lists" | "location-outline" | "location" | "lock" | "magic-wand" | "male" | "marketo" | "mention" | "message-preview-outline" | "message-preview" | "message" | "messages-outline" | "messages" | "messenger" | "metric-table" | "microsoft-dynamics" | "minus" | "mobile" | "monitor" | "moon" | "negative-sentiment" | "neutral-positive-sentiment" | "neutral-sentiment" | "new-trend" | "newspaper" | "no-access" | "notepad" | "notifications-publishing-outline" | "notifications-publishing" | "notifications" | "offline" | "online" | "paid-promotion-outline" | "paid-promotion" | "paid" | "paint" | "palette" | "paperclip" | "pause" | "pencil-outline" | "pencil" | "person" | "phone" | "pinterest-boards-outline" | "pinterest-boards" | "pinterest" | "play-circle" | "play" | "plus" | "positive-sentiment" | "power-up-outline" | "power-up" | "profile-connect" | "profile-disconnect" | "publishing-outline" | "publishing" | "puzzle-piece" | "qr-code" | "queue" | "recommendation" | "reddit-alien" | "reddit" | "referrals" | "refresh" | "rejected" | "reply-outline" | "reply" | "reporting-period" | "reporting" | "reports-home" | "reports" | "retweet" | "rss" | "sales" | "salesforce" | "save-assets" | "saved-messages" | "saved-reply-outline" | "saved-reply" | "search" | "sent-message-outline" | "sent-message" | "share" | "shopify" | "show-navigation" | "slack" | "small-density" | "smiley" | "some-access" | "sparkles" | "spike-alert" | "star-half-alt-solid" | "star-of-life" | "star-outline" | "star" | "sticky-note-outline" | "sticky-note" | "stories" | "story" | "suggestions" | "sun" | "tag-outline" | "tag" | "targeting-outline" | "targeting" | "tasks-outline" | "tasks" | "team-conversation-outline" | "team-conversation" | "team" | "text-asset" | "text" | "tiktok" | "times" | "trash-can-outline" | "trash-can" | "trend-down" | "trend-neutral" | "trend-up" | "trends" | "triangle-black" | "triangle" | "tripadvisor-circle-outline" | "tripadvisor-circle" | "tripadvisor" | "trophy-outline" | "tumblr" | "twitter-audience-network" | "twitter" | "unfollow-outline" | "unfollow" | "unlink" | "unlock" | "upload" | "user-circle" | "users" | "verified" | "video-camera-story" | "video-camera" | "vip" | "weight" | "whatsapp" | "window-maximize" | "window-minimize" | "window-regular" | "window-restore" | "woocommerce" | "x" | "yelp-full-star" | "yelp-half-star" | "yelp" | "youtube" | "zendesk";
2
+ export type EnumIconNames = "active-listener" | "add-item" | "add-keyword" | "add-team-member" | "add-variable" | "address-card-outline" | "address-card-solid" | "adobe-experience-manager" | "ads" | "android" | "apple" | "approval-indicator-outline" | "approval-indicator" | "archive" | "arrow-down-line" | "arrow-down" | "arrow-left-line" | "arrow-left" | "arrow-right-line" | "arrow-right" | "arrow-up-line" | "arrow-up" | "arrows" | "asset-library-outline" | "asset-library" | "assign" | "atom" | "audio" | "back-to-top" | "bambu-icon-outline" | "bambu-icon" | "barcode" | "basketball" | "bell-outline" | "bigcommerce" | "bitly" | "bold" | "book" | "bot" | "browser" | "business" | "calendar-outline" | "calendar" | "camera-outline" | "camera-story" | "camera" | "campaign" | "canva" | "carousel" | "cart-plus-outline" | "cart-plus" | "check" | "chevron-down-filled" | "chevron-down" | "chevron-left" | "chevron-right" | "chevron-up-down-filled" | "chevron-up-filled" | "chevron-up" | "circle-check-outline" | "circle-check" | "circle" | "circle+" | "circles" | "circlex" | "click-to-view" | "clicks" | "clipboard-outline" | "clipboard" | "clock" | "closed-captioning" | "cloud" | "code" | "columns" | "comment-alt-outline" | "comment-alt" | "comment-lines-alt-outline" | "comment" | "compact-density" | "compact-indicator" | "comparison" | "competitor" | "compose" | "content-suggestions" | "credit-card" | "crop" | "crown" | "dashboard" | "deconstructed-negative-sentiment" | "deconstructed-neutral-sentiment" | "deconstructed-positive-sentiment" | "discovery" | "dislike-outline" | "dislike" | "dm-link-outline" | "dm-link" | "dotdotdot" | "download" | "drafts-outline" | "drafts" | "dropbox" | "duplicate-outline" | "duplicate" | "emoji-outline" | "emoji" | "empty-image" | "engagement-per-post" | "engagements" | "error" | "exchange-alt" | "expanded-indicator" | "export" | "extended-circles" | "external-link-alt" | "external-link" | "extreme-negative-sentiment" | "eye-outline" | "eye-slash-outline" | "eye-slash" | "eye" | "facebook-audience-network" | "facebook-branded-content-outline" | "facebook-branded-content" | "facebook-groups" | "facebook" | "fb-reactions-angry" | "fb-reactions-haha" | "fb-reactions-like" | "fb-reactions-love" | "fb-reactions-sad" | "fb-reactions-wow" | "feedly" | "feeds" | "female" | "file-chart-line" | "file-edit" | "file-times-solid" | "filter" | "flag-outline" | "flag" | "flat-negative-sentiment-outline" | "flat-negative-sentiment" | "flat-neutral-sentiment-outline" | "flat-neutral-sentiment" | "flat-positive-sentiment-outline" | "flat-positive-sentiment" | "folder-open" | "folder" | "follow-outline" | "follow" | "follower-increase" | "following" | "font" | "full-access" | "gear" | "gears" | "glassdoor" | "glasses" | "globe" | "google-analytics-color" | "google-business-messages" | "google-drive" | "google-my-business" | "grip" | "h1" | "h2" | "hamburger" | "hashtag" | "headset" | "heart-outline" | "heart" | "heartbeat" | "help-alt" | "help" | "hiking" | "history" | "home" | "hourglass" | "hubspot" | "image-caption" | "image" | "images" | "impressions-per-post" | "impressions" | "inactive-listener" | "inbox-action" | "inbox-views" | "inbox" | "indicator" | "industry" | "info" | "instagram" | "internal-activity-outline" | "internal-activity" | "italic" | "key" | "keyboard" | "laptop-phone" | "large-density" | "lift" | "like-outline" | "like" | "link" | "linkedin-audience-network" | "linkedin" | "list-ol" | "listening" | "lists" | "location-outline" | "location" | "lock" | "magic-wand" | "male" | "marketo" | "mention" | "message-preview-outline" | "message-preview" | "message" | "messages-outline" | "messages" | "messenger" | "metric-table" | "microsoft-dynamics" | "minus" | "mobile" | "monitor" | "moon" | "negative-sentiment" | "neutral-positive-sentiment" | "neutral-sentiment" | "new-trend" | "newspaper" | "no-access" | "notepad" | "notifications-publishing-outline" | "notifications-publishing" | "notifications" | "offline" | "online" | "paid-promotion-outline" | "paid-promotion" | "paid" | "paint" | "palette" | "paperclip" | "pause" | "pencil-outline" | "pencil" | "person" | "phone" | "pinterest-boards-outline" | "pinterest-boards" | "pinterest" | "play-circle" | "play" | "plug" | "plus" | "positive-sentiment" | "power-up-outline" | "power-up" | "profile-connect" | "profile-disconnect" | "publishing-outline" | "publishing" | "puzzle-piece" | "qr-code" | "queue" | "recommendation" | "reddit-alien" | "reddit" | "referrals" | "refresh" | "rejected" | "reply-outline" | "reply" | "reporting-period" | "reporting" | "reports-home" | "reports" | "retweet" | "rss" | "sales" | "salesforce" | "save-assets" | "saved-messages" | "saved-reply-outline" | "saved-reply" | "search" | "sent-message-outline" | "sent-message" | "share" | "shopify" | "show-navigation" | "slack" | "small-density" | "smiley" | "some-access" | "sparkles" | "spike-alert" | "star-half-alt-solid" | "star-of-life" | "star-outline" | "star" | "sticky-note-outline" | "sticky-note" | "stories" | "story" | "suggestions" | "sun" | "tag-outline" | "tag" | "targeting-outline" | "targeting" | "tasks-outline" | "tasks" | "team-conversation-outline" | "team-conversation" | "team" | "text-asset" | "text" | "tiktok" | "times" | "trash-can-outline" | "trash-can" | "trend-down" | "trend-neutral" | "trend-up" | "trends" | "triangle-black" | "triangle" | "tripadvisor-circle-outline" | "tripadvisor-circle" | "tripadvisor" | "trophy-outline" | "tumblr" | "twitter-audience-network" | "twitter" | "unfollow-outline" | "unfollow" | "unlink" | "unlock" | "upload" | "user-circle" | "users" | "verified" | "video-camera-story" | "video-camera" | "vip" | "weight" | "whatsapp" | "window-maximize" | "window-minimize" | "window-regular" | "window-restore" | "woocommerce" | "x" | "yelp-full-star" | "yelp-half-star" | "yelp" | "youtube" | "zendesk";
@@ -1 +1 @@
1
- module.exports = {"active-listener":"0 0 16 16","add-item":"0 0 16 16","add-keyword":"0 0 16 16","add-team-member":"0 0 18 13","add-variable":"0 0 18 14","address-card-outline":"0 0 16 16","address-card-solid":"0 0 18 16","adobe-experience-manager":"0 0 16 18","ads":"0 0 9 16","android":"0 0 14 16","apple":"0 0 14 16","approval-indicator-outline":"0 0 14 16","approval-indicator":"0 0 14 16","archive":"0 0 16 16","arrow-down-line":"0 0 14 16","arrow-down":"0 0 16 16","arrow-left-line":"0 0 16 18","arrow-left":"0 0 16 16","arrow-right-line":"0 0 16 18","arrow-right":"0 0 16 16","arrow-up-line":"0 0 14 16","arrow-up":"0 0 16 16","arrows":"0 0 16 16","asset-library-outline":"0 0 16 16","asset-library":"0 0 16 16","assign":"0 0 18 15","atom":"0 0 14 16","audio":"0 0 16 14","back-to-top":"0 0 15 16","bambu-icon-outline":"0 0 16 16","bambu-icon":"0 0 16 16","barcode":"0 0 18 16","basketball":"0 0 16 16","bell-outline":"0 0 14 16","bigcommerce":"0 0 16 16","bitly":"0 0 16 16","bold":"0 0 16 16","book":"0 0 14 16","bot":"0 0 16 16","browser":"0 0 16 16","business":"0 0 16 16","calendar-outline":"0 0 14 16","calendar":"0 0 14 16","camera-outline":"0 0 18 16","camera-story":"0 0 18 16","camera":"0 0 18 16","campaign":"0 0 16 14","canva":"0 0 16 18","carousel":"0 0 16 18","cart-plus-outline":"0 0 17 15","cart-plus":"0 0 17 15","check":"0 0 16 16","chevron-down-filled":"0 0 16 21","chevron-down":"0 0 16 18","chevron-left":"0 0 10 16","chevron-right":"0 0 10 17","chevron-up-down-filled":"0 0 12 20","chevron-up-filled":"0 0 16 21","chevron-up":"0 0 16 18","circle-check-outline":"0 0 16 16","circle-check":"0 0 16 16","circle":"0 0 16 16","circle+":"0 0 16 16","circles":"0 0 16 16","circlex":"0 0 16 16","click-to-view":"0 0 12 16","clicks":"0 0 10 16","clipboard-outline":"0 0 12 16","clipboard":"0 0 12 16","clock":"0 0 16 16","closed-captioning":"0 0 16 16","cloud":"0 0 16 13","code":"0 0 18 16","columns":"0 0 16 16","comment-alt-outline":"0 0 16 15","comment-alt":"0 0 16 15","comment-lines-alt-outline":"0 0 16 16","comment":"0 0 16 13","compact-density":"0 0 16 16","compact-indicator":"0 0 16 16","comparison":"0 0 16 14","competitor":"0 0 14 16","compose":"0 0 16 16","content-suggestions":"0 0 16 16","credit-card":"0 0 16 14","crop":"0 0 16 16","crown":"0 0 16 16","dashboard":"0 0 16 14","deconstructed-negative-sentiment":"0 0 18 18","deconstructed-neutral-sentiment":"0 0 18 18","deconstructed-positive-sentiment":"0 0 18 18","discovery":"0 0 16 16","dislike-outline":"0 0 15 16","dislike":"0 0 16 16","dm-link-outline":"0 0 16 16","dm-link":"0 0 16 16","dotdotdot":"0 0 16 16","download":"0 0 16 16","drafts-outline":"0 0 12 16","drafts":"0 0 12 16","dropbox":"0 0 18 16","duplicate-outline":"0 0 14 16","duplicate":"0 0 14 16","emoji-outline":"0 0 16 16","emoji":"0 0 16 16","empty-image":"0 0 16 18","engagement-per-post":"0 0 16 16","engagements":"0 0 16 15","error":"0 0 16 16","exchange-alt":"0 0 16 16","expanded-indicator":"0 0 16 16","export":"0 0 14 17","extended-circles":"0 0 16 16","external-link-alt":"0 0 16 16","external-link":"0 0 16 16","extreme-negative-sentiment":"0 0 16 16","eye-outline":"0 0 18 16","eye-slash-outline":"0 0 20 16","eye-slash":"0 0 20 16","eye":"0 0 18 16","facebook-audience-network":"0 0 16 16","facebook-branded-content-outline":"0 0 18 15","facebook-branded-content":"0 0 18 15","facebook-groups":"0 0 16 16","facebook":"0 0 16 16","fb-reactions-angry":"0 0 16 16","fb-reactions-haha":"0 0 16 16","fb-reactions-like":"0 0 16 16","fb-reactions-love":"0 0 16 16","fb-reactions-sad":"0 0 16 16","fb-reactions-wow":"0 0 16 16","feedly":"0 0 16 15","feeds":"0 0 16 15","female":"0 0 11 18","file-chart-line":"0 0 12 16","file-edit":"0 0 12 16","file-times-solid":"0 0 12 16","filter":"0 0 16 16","flag-outline":"0 0 16 16","flag":"0 0 16 16","flat-negative-sentiment-outline":"0 0 18 18","flat-negative-sentiment":"0 0 18 18","flat-neutral-sentiment-outline":"0 0 18 18","flat-neutral-sentiment":"0 0 18 18","flat-positive-sentiment-outline":"0 0 18 18","flat-positive-sentiment":"0 0 18 18","folder-open":"0 0 16 15","folder":"0 0 16 16","follow-outline":"0 0 20 16","follow":"0 0 20 16","follower-increase":"0 0 19 16","following":"0 0 20 16","font":"0 0 18 16","full-access":"0 0 16 16","gear":"0 0 16 16","gears":"0 0 16 16","glassdoor":"0 0 16 16","glasses":"0 0 18 14","globe":"0 0 16 16","google-analytics-color":"0 0 14 18","google-business-messages":"0 0 16 16","google-drive":"0 0 16 14","google-my-business":"0 0 16 14","grip":"0 0 8 18","h1":"0 0 16 16","h2":"0 0 16 16","hamburger":"0 0 16 18","hashtag":"0 0 16 16","headset":"0 0 16 16","heart-outline":"0 0 16 16","heart":"0 0 16 16","heartbeat":"0 0 18 16","help":"0 0 16 16","hiking":"0 0 16 16","history":"0 0 16 16","home":"0 0 16 15","hourglass":"0 0 12 16","hubspot":"0 0 16 16","image-caption":"0 0 16 14","image":"0 0 16 16","images":"0 0 16 15","impressions-per-post":"0 0 16 16","impressions":"0 0 18 16","inactive-listener":"0 0 16 12","inbox-action":"0 0 16 16","inbox-views":"0 0 16 13","inbox":"0 0 16 14","indicator":"0 0 16 16","industry":"0 0 14 16","info":"0 0 16 16","instagram":"0 0 16 16","internal-activity-outline":"0 0 16 16","internal-activity":"0 0 16 16","italic":"0 0 16 16","key":"0 0 16 16","keyboard":"0 0 18 16","laptop-phone":"0 0 16 16","large-density":"0 0 16 16","lift":"0 0 23 16","like-outline":"0 0 15 16","like":"0 0 16 16","link":"0 0 16 16","linkedin-audience-network":"0 0 16 16","linkedin":"0 0 16 16","list-ol":"0 0 16 16","listening":"0 0 14 16","lists":"0 0 16 16","location-outline":"0 0 12 16","location":"0 0 12 16","lock":"0 0 14 16","magic-wand":"0 0 17 16","male":"0 0 16 20","marketo":"0 0 16 18","mention":"0 0 16 16","message-preview-outline":"0 0 18 16","message-preview":"0 0 18 16","message":"0 0 16 16","messages-outline":"0 0 16 16","messages":"0 0 16 16","messenger":"0 0 16 16","metric-table":"0 0 16 16","microsoft-dynamics":"0 0 16 16","minus":"0 0 16 16","mobile":"0 0 10 16","monitor":"0 0 12 16","moon":"0 0 15 16","negative-sentiment":"0 0 16 16","neutral-positive-sentiment":"0 0 16 16","neutral-sentiment":"0 0 16 16","new-trend":"0 0 12 16","newspaper":"0 0 16 16","no-access":"0 0 16 16","notepad":"0 0 12 16","notifications-publishing-outline":"0 0 16 16","notifications-publishing":"0 0 16 16","notifications":"0 0 14 16","offline":"0 0 18 15","online":"0 0 18 15","paid-promotion-outline":"0 0 16 16","paid-promotion":"0 0 16 16","paid":"0 0 14 16","paint":"0 0 18 16","palette":"0 0 16 16","paperclip":"0 0 14 16","pause":"0 0 16 18","pencil-outline":"0 0 16 16","pencil":"0 0 16 16","person":"0 0 14 16","phone":"0 0 16 16","pinterest-boards-outline":"0 0 14 16","pinterest-boards":"0 0 14 16","pinterest":"0 0 16 16","play-circle":"0 0 16 16","play":"0 0 14 16","plus":"0 0 16 18","positive-sentiment":"0 0 16 16","power-up-outline":"0 0 12 16","power-up":"0 0 10 16","profile-connect":"0 0 16 16","profile-disconnect":"0 0 16 16","publishing-outline":"0 0 16 16","publishing":"0 0 16 16","puzzle-piece":"0 0 18 16","qr-code":"0 0 16 16","queue":"0 0 16 16","recommendation":"0 0 16 16","reddit-alien":"0 0 16 16","reddit":"0 0 16 16","referrals":"0 0 16 16","refresh":"0 0 16 16","rejected":"0 0 16 16","reply-outline":"0 0 16 16","reply":"0 0 16 16","reporting-period":"0 0 14 16","reporting":"0 0 16 16","reports-home":"0 0 16 16","reports":"0 0 16 15","retweet":"0 0 18 16","rss":"0 0 16 16","sales":"0 0 9 16","salesforce":"0 0 20 16","save-assets":"0 0 16 16","saved-messages":"0 0 16 16","saved-reply-outline":"0 0 16 12","saved-reply":"0 0 16 12","search":"0 0 16 16","sent-message-outline":"0 0 16 14","sent-message":"0 0 16 14","share":"0 0 16 14","shopify":"0 0 16 18","show-navigation":"0 0 18 14","slack":"0 0 16 16","small-density":"0 0 16 16","smiley":"0 0 16 16","some-access":"0 0 16 16","sparkles":"0 0 16 16","spike-alert":"0 0 16 16","star-half-alt-solid":"0 0 18 16","star-of-life":"0 0 16 16","star-outline":"0 0 18 16","star":"0 0 18 16","sticky-note-outline":"0 0 16 16","sticky-note":"0 0 16 16","stories":"0 0 16 17","story":"0 0 16 16","suggestions":"0 0 11 16","sun":"0 0 16 16","tag-outline":"0 0 16 16","tag":"0 0 16 16","targeting-outline":"0 0 16 16","targeting":"0 0 16 16","tasks-outline":"0 0 12 16","tasks":"0 0 12 16","team-conversation-outline":"0 0 16 18","team-conversation":"0 0 16 18","team":"0 0 18 16","text-asset":"0 0 16 16","text":"0 0 8 16","tiktok":"0 0 16 18","times":"0 0 16 22","trash-can-outline":"0 0 14 16","trash-can":"0 0 14 16","trend-down":"0 0 18 18","trend-neutral":"0 0 20 18","trend-up":"0 0 18 18","trends":"0 0 16 17","triangle-black":"0 0 16 16","triangle":"0 0 16 16","tripadvisor-circle-outline":"0 0 16 16","tripadvisor-circle":"0 0 16 16","tripadvisor":"0 0 16 16","trophy-outline":"0 0 18 16","tumblr":"0 0 16 16","twitter-audience-network":"0 0 17 16","twitter":"0 0 17 16","unfollow-outline":"0 0 20 16","unfollow":"0 0 20 16","unlink":"0 0 16 16","unlock":"0 0 14 16","upload":"0 0 16 17","user-circle":"0 0 16 16","users":"0 0 18 16","verified":"0 0 16 16","video-camera-story":"0 0 18 15","video-camera":"0 0 18 16","vip":"0 0 16 16","weight":"0 0 16 16","whatsapp":"0 0 16 16","window-maximize":"0 0 16 16","window-minimize":"0 0 16 16","window-regular":"0 0 16 16","window-restore":"0 0 16 16","woocommerce":"0 0 18 16","x":"0 0 16 18","yelp-full-star":"0 0 16 16","yelp-half-star":"0 0 16 16","yelp":"0 0 14 16","youtube":"0 0 16 15","zendesk":"0 0 16 16"};
1
+ module.exports = {"active-listener":"0 0 16 16","add-item":"0 0 16 16","add-keyword":"0 0 16 16","add-team-member":"0 0 18 13","add-variable":"0 0 18 14","address-card-outline":"0 0 16 16","address-card-solid":"0 0 18 16","adobe-experience-manager":"0 0 16 18","ads":"0 0 9 16","android":"0 0 14 16","apple":"0 0 14 16","approval-indicator-outline":"0 0 14 16","approval-indicator":"0 0 14 16","archive":"0 0 16 16","arrow-down-line":"0 0 14 16","arrow-down":"0 0 16 16","arrow-left-line":"0 0 16 18","arrow-left":"0 0 16 16","arrow-right-line":"0 0 16 18","arrow-right":"0 0 16 16","arrow-up-line":"0 0 14 16","arrow-up":"0 0 16 16","arrows":"0 0 16 16","asset-library-outline":"0 0 16 16","asset-library":"0 0 16 16","assign":"0 0 18 15","atom":"0 0 14 16","audio":"0 0 16 14","back-to-top":"0 0 15 16","bambu-icon-outline":"0 0 16 16","bambu-icon":"0 0 16 16","barcode":"0 0 18 16","basketball":"0 0 16 16","bell-outline":"0 0 14 16","bigcommerce":"0 0 16 16","bitly":"0 0 16 16","bold":"0 0 16 16","book":"0 0 14 16","bot":"0 0 16 16","browser":"0 0 16 16","business":"0 0 16 16","calendar-outline":"0 0 14 16","calendar":"0 0 14 16","camera-outline":"0 0 18 16","camera-story":"0 0 18 16","camera":"0 0 18 16","campaign":"0 0 16 14","canva":"0 0 16 18","carousel":"0 0 16 18","cart-plus-outline":"0 0 17 15","cart-plus":"0 0 17 15","check":"0 0 16 16","chevron-down-filled":"0 0 16 21","chevron-down":"0 0 16 18","chevron-left":"0 0 10 16","chevron-right":"0 0 10 17","chevron-up-down-filled":"0 0 12 20","chevron-up-filled":"0 0 16 21","chevron-up":"0 0 16 18","circle-check-outline":"0 0 16 16","circle-check":"0 0 16 16","circle":"0 0 16 16","circle+":"0 0 16 16","circles":"0 0 16 16","circlex":"0 0 16 16","click-to-view":"0 0 12 16","clicks":"0 0 10 16","clipboard-outline":"0 0 12 16","clipboard":"0 0 12 16","clock":"0 0 16 16","closed-captioning":"0 0 16 16","cloud":"0 0 16 13","code":"0 0 18 16","columns":"0 0 16 16","comment-alt-outline":"0 0 16 15","comment-alt":"0 0 16 15","comment-lines-alt-outline":"0 0 16 16","comment":"0 0 16 13","compact-density":"0 0 16 16","compact-indicator":"0 0 16 16","comparison":"0 0 16 14","competitor":"0 0 14 16","compose":"0 0 16 16","content-suggestions":"0 0 16 16","credit-card":"0 0 16 14","crop":"0 0 16 16","crown":"0 0 16 16","dashboard":"0 0 16 14","deconstructed-negative-sentiment":"0 0 18 18","deconstructed-neutral-sentiment":"0 0 18 18","deconstructed-positive-sentiment":"0 0 18 18","discovery":"0 0 16 16","dislike-outline":"0 0 15 16","dislike":"0 0 16 16","dm-link-outline":"0 0 16 16","dm-link":"0 0 16 16","dotdotdot":"0 0 16 16","download":"0 0 16 16","drafts-outline":"0 0 12 16","drafts":"0 0 12 16","dropbox":"0 0 18 16","duplicate-outline":"0 0 14 16","duplicate":"0 0 14 16","emoji-outline":"0 0 16 16","emoji":"0 0 16 16","empty-image":"0 0 16 18","engagement-per-post":"0 0 16 16","engagements":"0 0 16 15","error":"0 0 16 16","exchange-alt":"0 0 16 16","expanded-indicator":"0 0 16 16","export":"0 0 14 17","extended-circles":"0 0 16 16","external-link-alt":"0 0 16 16","external-link":"0 0 16 16","extreme-negative-sentiment":"0 0 16 16","eye-outline":"0 0 18 16","eye-slash-outline":"0 0 20 16","eye-slash":"0 0 20 16","eye":"0 0 18 16","facebook-audience-network":"0 0 16 16","facebook-branded-content-outline":"0 0 18 15","facebook-branded-content":"0 0 18 15","facebook-groups":"0 0 16 16","facebook":"0 0 16 16","fb-reactions-angry":"0 0 16 16","fb-reactions-haha":"0 0 16 16","fb-reactions-like":"0 0 16 16","fb-reactions-love":"0 0 16 16","fb-reactions-sad":"0 0 16 16","fb-reactions-wow":"0 0 16 16","feedly":"0 0 16 15","feeds":"0 0 16 15","female":"0 0 11 18","file-chart-line":"0 0 12 16","file-edit":"0 0 12 16","file-times-solid":"0 0 12 16","filter":"0 0 16 16","flag-outline":"0 0 16 16","flag":"0 0 16 16","flat-negative-sentiment-outline":"0 0 18 18","flat-negative-sentiment":"0 0 18 18","flat-neutral-sentiment-outline":"0 0 18 18","flat-neutral-sentiment":"0 0 18 18","flat-positive-sentiment-outline":"0 0 18 18","flat-positive-sentiment":"0 0 18 18","folder-open":"0 0 16 15","folder":"0 0 16 16","follow-outline":"0 0 20 16","follow":"0 0 20 16","follower-increase":"0 0 19 16","following":"0 0 20 16","font":"0 0 18 16","full-access":"0 0 16 16","gear":"0 0 16 16","gears":"0 0 16 16","glassdoor":"0 0 16 16","glasses":"0 0 18 14","globe":"0 0 16 16","google-analytics-color":"0 0 14 18","google-business-messages":"0 0 16 16","google-drive":"0 0 16 14","google-my-business":"0 0 16 14","grip":"0 0 8 18","h1":"0 0 16 16","h2":"0 0 16 16","hamburger":"0 0 16 18","hashtag":"0 0 16 16","headset":"0 0 16 16","heart-outline":"0 0 16 16","heart":"0 0 16 16","heartbeat":"0 0 18 16","help-alt":"0 0 12 16","help":"0 0 16 16","hiking":"0 0 16 16","history":"0 0 16 16","home":"0 0 16 15","hourglass":"0 0 12 16","hubspot":"0 0 16 16","image-caption":"0 0 16 14","image":"0 0 16 16","images":"0 0 16 15","impressions-per-post":"0 0 16 16","impressions":"0 0 18 16","inactive-listener":"0 0 16 12","inbox-action":"0 0 16 16","inbox-views":"0 0 16 13","inbox":"0 0 16 14","indicator":"0 0 16 16","industry":"0 0 14 16","info":"0 0 16 16","instagram":"0 0 16 16","internal-activity-outline":"0 0 16 16","internal-activity":"0 0 16 16","italic":"0 0 16 16","key":"0 0 16 16","keyboard":"0 0 18 16","laptop-phone":"0 0 16 16","large-density":"0 0 16 16","lift":"0 0 23 16","like-outline":"0 0 15 16","like":"0 0 16 16","link":"0 0 16 16","linkedin-audience-network":"0 0 16 16","linkedin":"0 0 16 16","list-ol":"0 0 16 16","listening":"0 0 14 16","lists":"0 0 16 16","location-outline":"0 0 12 16","location":"0 0 12 16","lock":"0 0 14 16","magic-wand":"0 0 17 16","male":"0 0 16 20","marketo":"0 0 16 18","mention":"0 0 16 16","message-preview-outline":"0 0 18 16","message-preview":"0 0 18 16","message":"0 0 16 16","messages-outline":"0 0 16 16","messages":"0 0 16 16","messenger":"0 0 16 16","metric-table":"0 0 16 16","microsoft-dynamics":"0 0 16 16","minus":"0 0 16 16","mobile":"0 0 10 16","monitor":"0 0 12 16","moon":"0 0 15 16","negative-sentiment":"0 0 16 16","neutral-positive-sentiment":"0 0 16 16","neutral-sentiment":"0 0 16 16","new-trend":"0 0 12 16","newspaper":"0 0 16 16","no-access":"0 0 16 16","notepad":"0 0 12 16","notifications-publishing-outline":"0 0 16 16","notifications-publishing":"0 0 16 16","notifications":"0 0 14 16","offline":"0 0 18 15","online":"0 0 18 15","paid-promotion-outline":"0 0 16 16","paid-promotion":"0 0 16 16","paid":"0 0 14 16","paint":"0 0 18 16","palette":"0 0 16 16","paperclip":"0 0 14 16","pause":"0 0 16 18","pencil-outline":"0 0 16 16","pencil":"0 0 16 16","person":"0 0 14 16","phone":"0 0 16 16","pinterest-boards-outline":"0 0 14 16","pinterest-boards":"0 0 14 16","pinterest":"0 0 16 16","play-circle":"0 0 16 16","play":"0 0 14 16","plug":"0 0 12 16","plus":"0 0 16 18","positive-sentiment":"0 0 16 16","power-up-outline":"0 0 12 16","power-up":"0 0 10 16","profile-connect":"0 0 16 16","profile-disconnect":"0 0 16 16","publishing-outline":"0 0 16 16","publishing":"0 0 16 16","puzzle-piece":"0 0 18 16","qr-code":"0 0 16 16","queue":"0 0 16 16","recommendation":"0 0 16 16","reddit-alien":"0 0 16 16","reddit":"0 0 16 16","referrals":"0 0 16 16","refresh":"0 0 16 16","rejected":"0 0 16 16","reply-outline":"0 0 16 16","reply":"0 0 16 16","reporting-period":"0 0 14 16","reporting":"0 0 16 16","reports-home":"0 0 16 16","reports":"0 0 16 15","retweet":"0 0 18 16","rss":"0 0 16 16","sales":"0 0 9 16","salesforce":"0 0 20 16","save-assets":"0 0 16 16","saved-messages":"0 0 16 16","saved-reply-outline":"0 0 16 12","saved-reply":"0 0 16 12","search":"0 0 16 16","sent-message-outline":"0 0 16 14","sent-message":"0 0 16 14","share":"0 0 16 14","shopify":"0 0 16 18","show-navigation":"0 0 18 14","slack":"0 0 16 16","small-density":"0 0 16 16","smiley":"0 0 16 16","some-access":"0 0 16 16","sparkles":"0 0 16 16","spike-alert":"0 0 16 16","star-half-alt-solid":"0 0 18 16","star-of-life":"0 0 16 16","star-outline":"0 0 18 16","star":"0 0 18 16","sticky-note-outline":"0 0 16 16","sticky-note":"0 0 16 16","stories":"0 0 16 17","story":"0 0 16 16","suggestions":"0 0 11 16","sun":"0 0 16 16","tag-outline":"0 0 16 16","tag":"0 0 16 16","targeting-outline":"0 0 16 16","targeting":"0 0 16 16","tasks-outline":"0 0 12 16","tasks":"0 0 12 16","team-conversation-outline":"0 0 16 18","team-conversation":"0 0 16 18","team":"0 0 18 16","text-asset":"0 0 16 16","text":"0 0 8 16","tiktok":"0 0 16 18","times":"0 0 16 22","trash-can-outline":"0 0 14 16","trash-can":"0 0 14 16","trend-down":"0 0 18 18","trend-neutral":"0 0 20 18","trend-up":"0 0 18 18","trends":"0 0 16 17","triangle-black":"0 0 16 16","triangle":"0 0 16 16","tripadvisor-circle-outline":"0 0 16 16","tripadvisor-circle":"0 0 16 16","tripadvisor":"0 0 16 16","trophy-outline":"0 0 18 16","tumblr":"0 0 16 16","twitter-audience-network":"0 0 17 16","twitter":"0 0 17 16","unfollow-outline":"0 0 20 16","unfollow":"0 0 20 16","unlink":"0 0 16 16","unlock":"0 0 14 16","upload":"0 0 16 17","user-circle":"0 0 16 16","users":"0 0 18 16","verified":"0 0 16 16","video-camera-story":"0 0 18 15","video-camera":"0 0 18 16","vip":"0 0 16 16","weight":"0 0 16 16","whatsapp":"0 0 16 16","window-maximize":"0 0 16 16","window-minimize":"0 0 16 16","window-regular":"0 0 16 16","window-restore":"0 0 16 16","woocommerce":"0 0 18 16","x":"0 0 16 18","yelp-full-star":"0 0 16 16","yelp-half-star":"0 0 16 16","yelp":"0 0 14 16","youtube":"0 0 16 15","zendesk":"0 0 16 16"};
@@ -80,16 +80,8 @@ export default class Image extends React.Component<TypeProps, TypeState> {
80
80
  };
81
81
 
82
82
  render() {
83
- const {
84
- alt,
85
- title,
86
- onClick,
87
- onError,
88
- onLoad,
89
- src,
90
- qa,
91
- ...rest
92
- } = this.props;
83
+ const { alt, title, onClick, onError, onLoad, src, qa, ...rest } =
84
+ this.props;
93
85
 
94
86
  return (
95
87
  <ImageContainer
@@ -179,8 +179,8 @@ class Input extends React.Component<TypeProps, TypeState> {
179
179
  const nativeInputValueSetter = Object.getOwnPropertyDescriptor(
180
180
  window.HTMLInputElement.prototype,
181
181
  "value"
182
- ).set;
183
- nativeInputValueSetter.call(input, "");
182
+ )?.set;
183
+ nativeInputValueSetter?.call(input, "");
184
184
  const inputEvent = new Event("input", { bubbles: true });
185
185
  input.dispatchEvent(inputEvent);
186
186
 
@@ -141,50 +141,61 @@ leftAndRightIcons.story = {
141
141
  name: "Left and right icons",
142
142
  };
143
143
 
144
- export const searchInput = () => (
145
- <Input
146
- type="search"
147
- placeholder={text("placeholder", "Please enter a value...")}
148
- value={text("value", "val")}
149
- onClear={() => window.alert("Cleared!")}
150
- clearButtonLabel={text("clearButtonLabel", "Clear search")}
151
- ariaLabel={text("ariaLabel", "Descriptive label goes here")}
152
- />
153
- );
144
+ export const SearchInput = () => {
145
+ const [value, setValue] = React.useState("");
146
+ return (
147
+ <Input
148
+ type="search"
149
+ placeholder={text("placeholder", "Please enter a value...")}
150
+ value={value}
151
+ onChange={(e, value) => setValue(value)}
152
+ clearButtonLabel={text("clearButtonLabel", "Clear search")}
153
+ ariaLabel={text("ariaLabel", "Descriptive label goes here")}
154
+ />
155
+ );
156
+ };
154
157
 
155
- searchInput.story = {
158
+ SearchInput.story = {
156
159
  name: "Search Input",
157
160
  };
158
161
 
159
- export const smallSearchInput = () => (
160
- <Input
161
- type="search"
162
- size="small"
163
- placeholder={text("placeholder", "Please enter a value...")}
164
- value={text("value", "val")}
165
- onClear={() => window.alert("Cleared!")}
166
- clearButtonLabel={text("clearButtonLabel", "Clear search")}
167
- ariaLabel={text("ariaLabel", "Descriptive label goes here")}
168
- />
169
- );
162
+ export const SmallSearchInput = () => {
163
+ const [value, setValue] = React.useState("");
170
164
 
171
- smallSearchInput.story = {
165
+ return (
166
+ <Input
167
+ type="search"
168
+ size="small"
169
+ placeholder={text("placeholder", "Please enter a value...")}
170
+ value={value}
171
+ onChange={(e, value) => setValue(value)}
172
+ clearButtonLabel={text("clearButtonLabel", "Clear search")}
173
+ ariaLabel={text("ariaLabel", "Descriptive label goes here")}
174
+ />
175
+ );
176
+ };
177
+
178
+ SmallSearchInput.story = {
172
179
  name: "Small Search Input",
173
180
  };
174
181
 
175
- export const largeSearchInput = () => (
176
- <Input
177
- type="search"
178
- size="large"
179
- placeholder={text("placeholder", "Please enter a value...")}
180
- value={text("value", "val")}
181
- onClear={() => window.alert("Cleared!")}
182
- clearButtonLabel={text("clearButtonLabel", "Clear search")}
183
- ariaLabel={text("ariaLabel", "Descriptive label goes here")}
184
- />
185
- );
182
+ export const LargeSearchInput = () => {
183
+ const [value, setValue] = React.useState("");
186
184
 
187
- largeSearchInput.story = {
185
+ return (
186
+ <Input
187
+ type="search"
188
+ size="large"
189
+ placeholder={text("placeholder", "Please enter a value...")}
190
+ value={value}
191
+ onChange={(e, value) => setValue(value)}
192
+ clearButtonLabel={text("clearButtonLabel", "Clear search")}
193
+ ariaLabel={text("ariaLabel", "Descriptive label goes here")}
194
+ />
195
+ );
196
+ };
197
+
198
+ LargeSearchInput.story = {
188
199
  name: "Large Search Input",
189
200
  };
190
201
 
@@ -192,7 +203,6 @@ export const uncontrolledSearchInput = () => (
192
203
  <Input
193
204
  type="search"
194
205
  placeholder={text("placeholder", "Please enter a value...")}
195
- onClear={() => window.alert("Cleared!")}
196
206
  clearButtonLabel={text("clearButtonLabel", "Clear search")}
197
207
  ariaLabel={text("ariaLabel", "Descriptive label goes here")}
198
208
  />
@@ -202,13 +212,15 @@ uncontrolledSearchInput.story = {
202
212
  name: "Uncontrolled Search Input",
203
213
  };
204
214
 
205
- export const nonSearchClearButtonInput = () => {
215
+ export const NonSearchClearButtonInput = () => {
216
+ const [value, setValue] = React.useState("");
217
+
206
218
  return (
207
219
  <Input
208
220
  type="text"
209
221
  placeholder={text("placeholder", "Please enter a value...")}
210
- value={text("value", "val")}
211
- onClear={() => window.alert("Cleared!")}
222
+ value={value}
223
+ onChange={(e, value) => setValue(value)}
212
224
  ariaLabel={text("ariaLabel", "Descriptive label goes here")}
213
225
  clearButtonLabel={text("clearButtonLabel", "Clear text")}
214
226
  elemAfter={<Input.ClearButton />}
@@ -216,7 +228,7 @@ export const nonSearchClearButtonInput = () => {
216
228
  );
217
229
  };
218
230
 
219
- nonSearchClearButtonInput.story = {
231
+ NonSearchClearButtonInput.story = {
220
232
  name: "Manual Input.ClearButton usage",
221
233
  };
222
234
 
@@ -17,9 +17,8 @@ type TypeSegmentedControlContext = {
17
17
  onChange: (e: SyntheticInputEvent<HTMLInputElement>) => void,
18
18
  };
19
19
 
20
- const SegmentedControlContext = React.createContext<?TypeSegmentedControlContext>(
21
- null
22
- );
20
+ const SegmentedControlContext =
21
+ React.createContext<?TypeSegmentedControlContext>(null);
23
22
 
24
23
  type TypeSegmentedControlItemProps = {
25
24
  /** The value of this item. Should be unique among sibling items. */
@@ -22,15 +22,8 @@ export type TypeTableCell = {
22
22
  */
23
23
  export default class TableCell extends React.Component<TypeTableCell> {
24
24
  render() {
25
- const {
26
- id,
27
- content,
28
- colSpan,
29
- width,
30
- align,
31
- children,
32
- ...rest
33
- } = this.props;
25
+ const { id, content, colSpan, width, align, children, ...rest } =
26
+ this.props;
34
27
 
35
28
  return (
36
29
  <Container
@@ -32,15 +32,8 @@ export default class ToggleHint extends React.Component<TypeProps> {
32
32
  };
33
33
 
34
34
  render() {
35
- const {
36
- icon,
37
- isOpen,
38
- openString,
39
- closeString,
40
- qa,
41
- className,
42
- ...rest
43
- } = this.props;
35
+ const { icon, isOpen, openString, closeString, qa, className, ...rest } =
36
+ this.props;
44
37
 
45
38
  return (
46
39
  <Container
@@ -14,7 +14,8 @@ import type {
14
14
 
15
15
  // https://styled-system.com/table#color
16
16
 
17
- type TypeBackgroundColorSystemProp = TypeResponsiveBaseSystemProp<BackgroundColorProperty>;
17
+ type TypeBackgroundColorSystemProp =
18
+ TypeResponsiveBaseSystemProp<BackgroundColorProperty>;
18
19
  export type TypeColorSystemProps = $ReadOnly<{|
19
20
  backgroundColor?: TypeBackgroundColorSystemProp,
20
21
  bg?: TypeBackgroundColorSystemProp,
@@ -19,21 +19,13 @@ describe("normalizeResponsiveProp", () => {
19
19
 
20
20
  it("should handle arrays with 4 values", () => {
21
21
  expect(normalizeResponsiveProp([0, 1, 2, 3])).toMatchObject([
22
- 0,
23
- 1,
24
- 2,
25
- 3,
26
- 3,
22
+ 0, 1, 2, 3, 3,
27
23
  ]);
28
24
  });
29
25
 
30
26
  it("should handle arrays with 5 values", () => {
31
27
  expect(normalizeResponsiveProp([0, 1, 2, 3, 4])).toMatchObject([
32
- 0,
33
- 1,
34
- 2,
35
- 3,
36
- 4,
28
+ 0, 1, 2, 3, 4,
37
29
  ]);
38
30
  });
39
31
  });
@@ -173,6 +173,7 @@ module.exports = {
173
173
  "heart-outline": "0 0 16 16",
174
174
  "heart": "0 0 16 16",
175
175
  "heartbeat": "0 0 18 16",
176
+ "help-alt": "0 0 12 16",
176
177
  "help": "0 0 16 16",
177
178
  "hiking": "0 0 16 16",
178
179
  "history": "0 0 16 16",
@@ -255,6 +256,7 @@ module.exports = {
255
256
  "pinterest": "0 0 16 16",
256
257
  "play-circle": "0 0 16 16",
257
258
  "play": "0 0 14 16",
259
+ "plug": "0 0 12 16",
258
260
  "plus": "0 0 16 18",
259
261
  "positive-sentiment": "0 0 16 16",
260
262
  "power-up-outline": "0 0 12 16",
@@ -101,9 +101,11 @@ var Input = /*#__PURE__*/function (_React$Component) {
101
101
  var input = _this.inputRef.current;
102
102
 
103
103
  if (input) {
104
+ var _Object$getOwnPropert;
105
+
104
106
  // Clear the value via the input prototype, then dispatch an input event in order to trigger handleChange
105
- var nativeInputValueSetter = Object.getOwnPropertyDescriptor(window.HTMLInputElement.prototype, "value").set;
106
- nativeInputValueSetter.call(input, "");
107
+ var nativeInputValueSetter = (_Object$getOwnPropert = Object.getOwnPropertyDescriptor(window.HTMLInputElement.prototype, "value")) == null ? void 0 : _Object$getOwnPropert.set;
108
+ nativeInputValueSetter == null ? void 0 : nativeInputValueSetter.call(input, "");
107
109
  var inputEvent = new Event("input", {
108
110
  bubbles: true
109
111
  });