@zendeskgarden/react-buttons 9.0.0-next.21 → 9.0.0-next.23

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.
@@ -39,7 +39,7 @@ const Anchor = forwardRef((_ref, ref) => {
39
39
  return React__default.createElement(StyledAnchor, Object.assign({
40
40
  ref: ref,
41
41
  $isUnderlined: isUnderlined
42
- }, anchorProps), children, isExternal &&
42
+ }, anchorProps), children, !!isExternal &&
43
43
  React__default.createElement(StyledExternalIcon, {
44
44
  role: "img",
45
45
  "aria-label": iconAriaLabel,
@@ -11,7 +11,7 @@ import { StyledButton } from './StyledButton.js';
11
11
  const COMPONENT_ID = 'buttons.anchor';
12
12
  const StyledAnchor = styled(StyledButton).attrs(props => ({
13
13
  'data-garden-id': COMPONENT_ID,
14
- 'data-garden-version': '9.0.0-next.21',
14
+ 'data-garden-version': '9.0.0-next.23',
15
15
  as: 'a',
16
16
  dir: props.theme.rtl ? 'rtl' : undefined,
17
17
  isLink: true,
@@ -308,7 +308,7 @@ const sizeStyles = props => {
308
308
  };
309
309
  const StyledButton = styled.button.attrs(props => ({
310
310
  'data-garden-id': props['data-garden-id'] || COMPONENT_ID,
311
- 'data-garden-version': '9.0.0-next.21',
311
+ 'data-garden-version': '9.0.0-next.23',
312
312
  type: props.type || 'button'
313
313
  })).withConfig({
314
314
  displayName: "StyledButton",
@@ -11,7 +11,7 @@ import { retrieveComponentStyles, DEFAULT_THEME } from '@zendeskgarden/react-the
11
11
  const COMPONENT_ID = 'buttons.external_icon';
12
12
  const StyledExternalIcon = styled(SvgNewWindowStroke).attrs({
13
13
  'data-garden-id': COMPONENT_ID,
14
- 'data-garden-version': '9.0.0-next.21'
14
+ 'data-garden-version': '9.0.0-next.23'
15
15
  }).withConfig({
16
16
  displayName: "StyledExternalIcon",
17
17
  componentId: "sc-16oz07e-0"
@@ -19,7 +19,7 @@ const sizeStyles = props => {
19
19
  };
20
20
  const StyledIcon = styled(StyledBaseIcon).attrs({
21
21
  'data-garden-id': COMPONENT_ID,
22
- 'data-garden-version': '9.0.0-next.21'
22
+ 'data-garden-version': '9.0.0-next.23'
23
23
  }).withConfig({
24
24
  displayName: "StyledIcon",
25
25
  componentId: "sc-19meqgg-0"
@@ -51,7 +51,7 @@ const StyledIconButton = styled(StyledButton).attrs(props => {
51
51
  const externalId = props['data-garden-id'];
52
52
  return {
53
53
  'data-garden-id': externalId && externalId !== COMPONENT_ID$1 ? externalId : COMPONENT_ID,
54
- 'data-garden-version': '9.0.0-next.21'
54
+ 'data-garden-version': '9.0.0-next.23'
55
55
  };
56
56
  }).withConfig({
57
57
  displayName: "StyledIconButton",
@@ -10,7 +10,7 @@ import { retrieveComponentStyles, DEFAULT_THEME } from '@zendeskgarden/react-the
10
10
  const COMPONENT_ID = 'buttons.button_group_view';
11
11
  const StyledSplitButton = styled.div.attrs({
12
12
  'data-garden-id': COMPONENT_ID,
13
- 'data-garden-version': '9.0.0-next.21'
13
+ 'data-garden-version': '9.0.0-next.23'
14
14
  }).withConfig({
15
15
  displayName: "StyledSplitButton",
16
16
  componentId: "sc-1u4v04v-0"
package/dist/index.cjs.js CHANGED
@@ -41,7 +41,7 @@ const SIZE = ['small', 'medium', 'large'];
41
41
  const COMPONENT_ID$5 = 'buttons.button_group_view';
42
42
  const StyledSplitButton = styled__default.default.div.attrs({
43
43
  'data-garden-id': COMPONENT_ID$5,
44
- 'data-garden-version': '9.0.0-next.21'
44
+ 'data-garden-version': '9.0.0-next.23'
45
45
  }).withConfig({
46
46
  displayName: "StyledSplitButton",
47
47
  componentId: "sc-1u4v04v-0"
@@ -62,7 +62,7 @@ const sizeStyles$1 = props => {
62
62
  };
63
63
  const StyledIcon = styled__default.default(reactTheming.StyledBaseIcon).attrs({
64
64
  'data-garden-id': COMPONENT_ID$4,
65
- 'data-garden-version': '9.0.0-next.21'
65
+ 'data-garden-version': '9.0.0-next.23'
66
66
  }).withConfig({
67
67
  displayName: "StyledIcon",
68
68
  componentId: "sc-19meqgg-0"
@@ -369,7 +369,7 @@ const sizeStyles = props => {
369
369
  };
370
370
  const StyledButton = styled__default.default.button.attrs(props => ({
371
371
  'data-garden-id': props['data-garden-id'] || COMPONENT_ID$3,
372
- 'data-garden-version': '9.0.0-next.21',
372
+ 'data-garden-version': '9.0.0-next.23',
373
373
  type: props.type || 'button'
374
374
  })).withConfig({
375
375
  displayName: "StyledButton",
@@ -382,7 +382,7 @@ StyledButton.defaultProps = {
382
382
  const COMPONENT_ID$2 = 'buttons.anchor';
383
383
  const StyledAnchor = styled__default.default(StyledButton).attrs(props => ({
384
384
  'data-garden-id': COMPONENT_ID$2,
385
- 'data-garden-version': '9.0.0-next.21',
385
+ 'data-garden-version': '9.0.0-next.23',
386
386
  as: 'a',
387
387
  dir: props.theme.rtl ? 'rtl' : undefined,
388
388
  isLink: true,
@@ -416,7 +416,7 @@ var SvgNewWindowStroke = function SvgNewWindowStroke(props) {
416
416
  const COMPONENT_ID$1 = 'buttons.external_icon';
417
417
  const StyledExternalIcon = styled__default.default(SvgNewWindowStroke).attrs({
418
418
  'data-garden-id': COMPONENT_ID$1,
419
- 'data-garden-version': '9.0.0-next.21'
419
+ 'data-garden-version': '9.0.0-next.23'
420
420
  }).withConfig({
421
421
  displayName: "StyledExternalIcon",
422
422
  componentId: "sc-16oz07e-0"
@@ -467,7 +467,7 @@ const StyledIconButton = styled__default.default(StyledButton).attrs(props => {
467
467
  const externalId = props['data-garden-id'];
468
468
  return {
469
469
  'data-garden-id': externalId && externalId !== COMPONENT_ID$3 ? externalId : COMPONENT_ID,
470
- 'data-garden-version': '9.0.0-next.21'
470
+ 'data-garden-version': '9.0.0-next.23'
471
471
  };
472
472
  }).withConfig({
473
473
  displayName: "StyledIconButton",
@@ -563,7 +563,7 @@ const Anchor = React.forwardRef((_ref, ref) => {
563
563
  return React__namespace.default.createElement(StyledAnchor, Object.assign({
564
564
  ref: ref,
565
565
  $isUnderlined: isUnderlined
566
- }, anchorProps), children, isExternal &&
566
+ }, anchorProps), children, !!isExternal &&
567
567
  React__namespace.default.createElement(StyledExternalIcon, {
568
568
  role: "img",
569
569
  "aria-label": iconAriaLabel,
@@ -8,10 +8,12 @@ import React from 'react';
8
8
  import { IButtonProps } from '../types';
9
9
  import { StartIcon } from './components/StartIcon';
10
10
  import { EndIcon } from './components/EndIcon';
11
+ declare const ButtonComponent: React.ForwardRefExoticComponent<IButtonProps & React.RefAttributes<HTMLButtonElement>>;
11
12
  /**
12
13
  * @extends ButtonHTMLAttributes<HTMLButtonElement>
13
14
  */
14
- export declare const Button: React.ForwardRefExoticComponent<IButtonProps & React.RefAttributes<HTMLButtonElement>> & {
15
+ export declare const Button: typeof ButtonComponent & {
15
16
  EndIcon: typeof EndIcon;
16
17
  StartIcon: typeof StartIcon;
17
18
  };
19
+ export {};
@@ -4,7 +4,6 @@
4
4
  * Use of this source code is governed under the Apache License, Version 2.0
5
5
  * found at http://www.apache.org/licenses/LICENSE-2.0.
6
6
  */
7
- /// <reference types="react" />
8
7
  import { DefaultTheme } from 'styled-components';
9
8
  interface IStyledIconProps {
10
9
  $isRotated: boolean;
@@ -4,6 +4,5 @@
4
4
  * Use of this source code is governed under the Apache License, Version 2.0
5
5
  * found at http://www.apache.org/licenses/LICENSE-2.0.
6
6
  */
7
- /// <reference types="react" />
8
7
  export declare const SplitButtonContext: import("react").Context<boolean | undefined>;
9
8
  export declare const useSplitButtonContext: () => boolean | undefined;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@zendeskgarden/react-buttons",
3
- "version": "9.0.0-next.21",
3
+ "version": "9.0.0-next.23",
4
4
  "description": "Components relating to buttons in the Garden Design System",
5
5
  "license": "Apache-2.0",
6
6
  "author": "Zendesk Garden <garden@zendesk.com>",
@@ -28,13 +28,13 @@
28
28
  },
29
29
  "peerDependencies": {
30
30
  "@zendeskgarden/react-theming": ">=9.0.0-next",
31
- "react": ">=16.8.0",
32
- "react-dom": ">=16.8.0",
31
+ "react": "^16.8.0 || ^17.0.0 || ^18.0.0",
32
+ "react-dom": "^16.8.0 || ^17.0.0 || ^18.0.0",
33
33
  "styled-components": "^5.3.1"
34
34
  },
35
35
  "devDependencies": {
36
- "@zendeskgarden/react-theming": "^9.0.0-next.21",
37
- "@zendeskgarden/svg-icons": "7.1.1"
36
+ "@zendeskgarden/react-theming": "^9.0.0-next.23",
37
+ "@zendeskgarden/svg-icons": "7.2.0"
38
38
  },
39
39
  "keywords": [
40
40
  "components",
@@ -46,5 +46,5 @@
46
46
  "access": "public"
47
47
  },
48
48
  "zendeskgarden:src": "src/index.ts",
49
- "gitHead": "a245ce2b794ea65142174a6a1f855a111b2677a2"
49
+ "gitHead": "5e7d2ed69a1615e09406a3f9285359346bb90cc7"
50
50
  }