@atlaskit/flag 14.5.1 → 14.5.4

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.
Files changed (47) hide show
  1. package/CHANGELOG.md +22 -0
  2. package/__perf__/withFlagGroup.tsx +1 -1
  3. package/dist/cjs/auto-dismiss-flag.js +4 -4
  4. package/dist/cjs/flag-actions.js +50 -6
  5. package/dist/cjs/flag-group.js +56 -18
  6. package/dist/cjs/flag.js +83 -106
  7. package/dist/cjs/internal/description.js +32 -0
  8. package/dist/cjs/internal/dismiss-button.js +83 -0
  9. package/dist/cjs/{expander.js → internal/expander.js} +15 -7
  10. package/dist/cjs/internal/index.js +39 -0
  11. package/dist/cjs/internal/title.js +32 -0
  12. package/dist/cjs/theme.js +61 -61
  13. package/dist/cjs/version.json +1 -1
  14. package/dist/es2019/auto-dismiss-flag.js +2 -3
  15. package/dist/es2019/flag-actions.js +50 -32
  16. package/dist/es2019/flag-group.js +48 -65
  17. package/dist/es2019/flag.js +77 -164
  18. package/dist/es2019/internal/description.js +22 -0
  19. package/dist/es2019/internal/dismiss-button.js +63 -0
  20. package/dist/es2019/{expander.js → internal/expander.js} +14 -10
  21. package/dist/es2019/internal/index.js +4 -0
  22. package/dist/es2019/internal/title.js +22 -0
  23. package/dist/es2019/theme.js +61 -61
  24. package/dist/es2019/version.json +1 -1
  25. package/dist/esm/auto-dismiss-flag.js +2 -3
  26. package/dist/esm/flag-actions.js +49 -6
  27. package/dist/esm/flag-group.js +52 -16
  28. package/dist/esm/flag.js +79 -101
  29. package/dist/esm/internal/description.js +23 -0
  30. package/dist/esm/internal/dismiss-button.js +63 -0
  31. package/dist/esm/{expander.js → internal/expander.js} +14 -5
  32. package/dist/esm/internal/index.js +4 -0
  33. package/dist/esm/internal/title.js +23 -0
  34. package/dist/esm/theme.js +61 -61
  35. package/dist/esm/version.json +1 -1
  36. package/dist/types/flag-actions.d.ts +4 -4
  37. package/dist/types/flag-group.d.ts +2 -2
  38. package/dist/types/flag.d.ts +1 -1
  39. package/dist/types/internal/description.d.ts +7 -0
  40. package/dist/types/internal/dismiss-button.d.ts +11 -0
  41. package/dist/types/internal/expander.d.ts +8 -0
  42. package/dist/types/internal/index.d.ts +4 -0
  43. package/dist/types/internal/title.d.ts +6 -0
  44. package/dist/types/theme.d.ts +1 -1
  45. package/package.json +8 -4
  46. package/dist/types/expander.d.ts +0 -9
  47. package/expander/package.json +0 -7
@@ -0,0 +1,23 @@
1
+ /** @jsx jsx */
2
+ import { jsx, css } from '@emotion/core';
3
+ var descriptionStyles = css({
4
+ /* height is defined as 5 lines maximum by design */
5
+ maxHeight: 100,
6
+ overflow: 'auto',
7
+ wordWrap: 'break-word'
8
+ });
9
+
10
+ var Description = function Description(_ref) {
11
+ var color = _ref.color,
12
+ testId = _ref.testId,
13
+ children = _ref.children;
14
+ return jsx("div", {
15
+ style: {
16
+ color: color
17
+ },
18
+ css: descriptionStyles,
19
+ "data-testid": testId
20
+ }, children);
21
+ };
22
+
23
+ export default Description;
@@ -0,0 +1,63 @@
1
+ /** @jsx jsx */
2
+ import { memo } from 'react';
3
+ import { jsx, css } from '@emotion/core';
4
+ import FocusRing from '@atlaskit/focus-ring';
5
+ import ChevronDownIcon from '@atlaskit/icon/glyph/chevron-down';
6
+ import ChevronUpIcon from '@atlaskit/icon/glyph/chevron-up';
7
+ import CrossIcon from '@atlaskit/icon/glyph/cross';
8
+ import { borderRadius as getBorderRadius, gridSize as getGridSize } from '@atlaskit/theme/constants';
9
+ import { useGlobalTheme } from '@atlaskit/theme/components';
10
+ import { getFlagTextColor } from '../theme';
11
+ var gridSize = getGridSize();
12
+ var borderRadius = getBorderRadius();
13
+ var dismissButtonStyles = css({
14
+ marginLeft: gridSize,
15
+ padding: 0,
16
+ flex: '0 0 auto',
17
+ appearance: 'none',
18
+ background: 'none',
19
+ border: 'none',
20
+ borderRadius: borderRadius,
21
+ cursor: 'pointer',
22
+ lineHeight: '1',
23
+ whiteSpace: 'nowrap'
24
+ });
25
+
26
+ var DismissButton = function DismissButton(_ref) {
27
+ var appearance = _ref.appearance,
28
+ onClick = _ref.onClick,
29
+ isBold = _ref.isBold,
30
+ isExpanded = _ref.isExpanded,
31
+ testId = _ref.testId;
32
+
33
+ var _useGlobalTheme = useGlobalTheme(),
34
+ mode = _useGlobalTheme.mode;
35
+
36
+ var ButtonIcon = CrossIcon;
37
+ var buttonLabel = 'Dismiss';
38
+ var size = 'small';
39
+ var buttonTestId = testId && "".concat(testId, "-dismiss");
40
+
41
+ if (isBold) {
42
+ ButtonIcon = isExpanded ? ChevronUpIcon : ChevronDownIcon;
43
+ buttonLabel = isExpanded ? 'Collapse' : 'Expand';
44
+ size = 'large';
45
+ buttonTestId = testId && "".concat(testId, "-toggle");
46
+ }
47
+
48
+ return jsx(FocusRing, null, jsx("button", {
49
+ style: {
50
+ color: getFlagTextColor(appearance, mode)
51
+ },
52
+ css: dismissButtonStyles,
53
+ onClick: onClick,
54
+ "data-testid": buttonTestId,
55
+ type: "button",
56
+ "aria-expanded": isBold ? isExpanded : undefined
57
+ }, jsx(ButtonIcon, {
58
+ label: buttonLabel,
59
+ size: size
60
+ })));
61
+ };
62
+
63
+ export default /*#__PURE__*/memo(DismissButton);
@@ -1,12 +1,21 @@
1
- import _taggedTemplateLiteral from "@babel/runtime/helpers/taggedTemplateLiteral";
2
-
3
- var _templateObject;
4
-
5
1
  /** @jsx jsx */
6
2
  import { css, jsx } from '@emotion/core';
7
3
  import { ExitingPersistence, FadeIn } from '@atlaskit/motion';
8
4
  import { gridSize } from '@atlaskit/theme/constants';
9
5
  var paddingLeft = gridSize() * 5;
6
+ var expanderStyles = css({
7
+ display: 'flex',
8
+ minWidth: 0,
9
+ maxHeight: 0,
10
+ padding: "0 0 0 ".concat(paddingLeft, "px"),
11
+ justifyContent: 'center',
12
+ flex: '1 1 100%',
13
+ flexDirection: 'column',
14
+ transition: "max-height 0.3s"
15
+ });
16
+ var expandedStyles = css({
17
+ maxHeight: 150
18
+ });
10
19
 
11
20
  var Expander = function Expander(_ref) {
12
21
  var children = _ref.children,
@@ -17,7 +26,7 @@ var Expander = function Expander(_ref) {
17
26
  // the the reveal because we don't know the height of the content.
18
27
  return jsx("div", {
19
28
  "aria-hidden": !isExpanded,
20
- css: css(_templateObject || (_templateObject = _taggedTemplateLiteral(["\n max-height: ", "px;\n transition: max-height 0.3s;\n display: flex;\n flex: 1 1 100%;\n flex-direction: column;\n justify-content: center;\n min-width: 0;\n padding: 0 0 0 ", "px;\n "])), isExpanded ? 150 : 0, paddingLeft),
29
+ css: [expanderStyles, isExpanded && expandedStyles],
21
30
  "data-testid": testId && "".concat(testId, "-expander")
22
31
  }, jsx(ExitingPersistence, {
23
32
  appear: true
@@ -0,0 +1,4 @@
1
+ export { default as Title } from './title';
2
+ export { default as Description } from './description';
3
+ export { default as Expander } from './expander';
4
+ export { default as DismissButton } from './dismiss-button';
@@ -0,0 +1,23 @@
1
+ /** @jsx jsx */
2
+ import { jsx, css } from '@emotion/core';
3
+ var titleStyles = css({
4
+ padding: "0 0 0 16px",
5
+ flex: 1,
6
+ fontWeight: 600,
7
+ overflow: 'hidden',
8
+ textOverflow: 'ellipsis',
9
+ whiteSpace: 'nowrap'
10
+ });
11
+
12
+ var Title = function Title(_ref) {
13
+ var color = _ref.color,
14
+ children = _ref.children;
15
+ return jsx("span", {
16
+ style: {
17
+ color: color
18
+ },
19
+ css: titleStyles
20
+ }, children);
21
+ };
22
+
23
+ export default Title;
package/dist/esm/theme.js CHANGED
@@ -1,72 +1,72 @@
1
1
  import { B100, B400, DN40, DN50, DN600, G300, G400, N0, N200, N30A, N40, N500, N50A, N60A, N700, R300, R400, Y200, Y300 } from '@atlaskit/theme/colors';
2
2
  var flagBackgroundColor = {
3
3
  error: {
4
- light: "var(--ds-background-overlay, ".concat(R400, ")"),
5
- dark: "var(--ds-background-overlay, ".concat(R300, ")")
4
+ light: "var(--ds-surface-overlay, ".concat(R400, ")"),
5
+ dark: "var(--ds-surface-overlay, ".concat(R300, ")")
6
6
  },
7
7
  info: {
8
- light: "var(--ds-background-overlay, ".concat(N500, ")"),
9
- dark: "var(--ds-background-overlay, ".concat(N500, ")")
8
+ light: "var(--ds-surface-overlay, ".concat(N500, ")"),
9
+ dark: "var(--ds-surface-overlay, ".concat(N500, ")")
10
10
  },
11
11
  normal: {
12
- light: "var(--ds-background-overlay, ".concat(N0, ")"),
13
- dark: "var(--ds-background-overlay, ".concat(DN50, ")")
12
+ light: "var(--ds-surface-overlay, ".concat(N0, ")"),
13
+ dark: "var(--ds-surface-overlay, ".concat(DN50, ")")
14
14
  },
15
15
  success: {
16
- light: "var(--ds-background-overlay, ".concat(G400, ")"),
17
- dark: "var(--ds-background-overlay, ".concat(G300, ")")
16
+ light: "var(--ds-surface-overlay, ".concat(G400, ")"),
17
+ dark: "var(--ds-surface-overlay, ".concat(G300, ")")
18
18
  },
19
19
  warning: {
20
- light: "var(--ds-background-overlay, ".concat(Y200, ")"),
21
- dark: "var(--ds-background-overlay, ".concat(Y300, ")")
20
+ light: "var(--ds-surface-overlay, ".concat(Y200, ")"),
21
+ dark: "var(--ds-surface-overlay, ".concat(Y300, ")")
22
22
  }
23
23
  };
24
24
  export var getFlagBackgroundColor = function getFlagBackgroundColor(appearance, mode) {
25
25
  return flagBackgroundColor[appearance][mode];
26
26
  };
27
- export var flagBorderColor = "var(--ds-background-overlay, ".concat(N60A, ")");
27
+ export var flagBorderColor = "var(--ds-surface-overlay, ".concat(N60A, ")");
28
28
  var flagIconColor = {
29
29
  error: {
30
- light: "var(--ds-iconBorder-danger, ".concat(N0, ")"),
31
- dark: "var(--ds-iconBorder-danger, ".concat(DN40, ")")
30
+ light: "var(--ds-icon-danger, ".concat(N0, ")"),
31
+ dark: "var(--ds-icon-danger, ".concat(DN40, ")")
32
32
  },
33
33
  info: {
34
- light: "var(--ds-iconBorder-discovery, ".concat(N0, ")"),
35
- dark: "var(--ds-iconBorder-discovery, ".concat(DN600, ")")
34
+ light: "var(--ds-icon-discovery, ".concat(N0, ")"),
35
+ dark: "var(--ds-icon-discovery, ".concat(DN600, ")")
36
36
  },
37
37
  normal: {
38
- light: "var(--ds-iconBorder-brand, ".concat(N500, ")"),
39
- dark: "var(--ds-iconBorder-brand, ".concat(DN600, ")")
38
+ light: "var(--ds-icon-brand, ".concat(N500, ")"),
39
+ dark: "var(--ds-icon-brand, ".concat(DN600, ")")
40
40
  },
41
41
  success: {
42
- light: "var(--ds-iconBorder-success, ".concat(N0, ")"),
43
- dark: "var(--ds-iconBorder-success, ".concat(DN40, ")")
42
+ light: "var(--ds-icon-success, ".concat(N0, ")"),
43
+ dark: "var(--ds-icon-success, ".concat(DN40, ")")
44
44
  },
45
45
  warning: {
46
- light: "var(--ds-iconBorder-warning, ".concat(N700, ")"),
47
- dark: "var(--ds-iconBorder-warning, ".concat(DN40, ")")
46
+ light: "var(--ds-icon-warning, ".concat(N700, ")"),
47
+ dark: "var(--ds-icon-warning, ".concat(DN40, ")")
48
48
  }
49
49
  };
50
50
  var flagTextColor = {
51
51
  error: {
52
- light: "var(--ds-text-highEmphasis, ".concat(N0, ")"),
53
- dark: "var(--ds-text-highEmphasis, ".concat(DN40, ")")
52
+ light: "var(--ds-text, ".concat(N0, ")"),
53
+ dark: "var(--ds-text, ".concat(DN40, ")")
54
54
  },
55
55
  info: {
56
- light: "var(--ds-text-highEmphasis, ".concat(N0, ")"),
57
- dark: "var(--ds-text-highEmphasis, ".concat(DN600, ")")
56
+ light: "var(--ds-text, ".concat(N0, ")"),
57
+ dark: "var(--ds-text, ".concat(DN600, ")")
58
58
  },
59
59
  normal: {
60
- light: "var(--ds-text-highEmphasis, ".concat(N500, ")"),
61
- dark: "var(--ds-text-highEmphasis, ".concat(DN600, ")")
60
+ light: "var(--ds-text, ".concat(N500, ")"),
61
+ dark: "var(--ds-text, ".concat(DN600, ")")
62
62
  },
63
63
  success: {
64
- light: "var(--ds-text-highEmphasis, ".concat(N0, ")"),
65
- dark: "var(--ds-text-highEmphasis, ".concat(DN40, ")")
64
+ light: "var(--ds-text, ".concat(N0, ")"),
65
+ dark: "var(--ds-text, ".concat(DN40, ")")
66
66
  },
67
67
  warning: {
68
- light: "var(--ds-text-highEmphasis, ".concat(N700, ")"),
69
- dark: "var(--ds-text-highEmphasis, ".concat(DN40, ")")
68
+ light: "var(--ds-text, ".concat(N700, ")"),
69
+ dark: "var(--ds-text, ".concat(DN40, ")")
70
70
  }
71
71
  };
72
72
  export var getFlagTextColor = function getFlagTextColor(appearance, mode) {
@@ -80,24 +80,24 @@ export var getFlagIconColor = function getFlagIconColor(appearance, mode) {
80
80
  export var flagShadowColor = N50A;
81
81
  var flagFocusRingColor = {
82
82
  error: {
83
- light: "var(--ds-border-focus, ".concat(N40, ")"),
84
- dark: "var(--ds-border-focus, ".concat(N40, ")")
83
+ light: "var(--ds-border-focused, ".concat(N40, ")"),
84
+ dark: "var(--ds-border-focused, ".concat(N40, ")")
85
85
  },
86
86
  info: {
87
- light: "var(--ds-border-focus, ".concat(N40, ")"),
88
- dark: "var(--ds-border-focus, ".concat(N40, ")")
87
+ light: "var(--ds-border-focused, ".concat(N40, ")"),
88
+ dark: "var(--ds-border-focused, ".concat(N40, ")")
89
89
  },
90
90
  normal: {
91
- light: "var(--ds-border-focus, ".concat(B100, ")"),
92
- dark: "var(--ds-border-focus, ".concat(B100, ")")
91
+ light: "var(--ds-border-focused, ".concat(B100, ")"),
92
+ dark: "var(--ds-border-focused, ".concat(B100, ")")
93
93
  },
94
94
  success: {
95
- light: "var(--ds-border-focus, ".concat(N40, ")"),
96
- dark: "var(--ds-border-focus, ".concat(N40, ")")
95
+ light: "var(--ds-border-focused, ".concat(N40, ")"),
96
+ dark: "var(--ds-border-focused, ".concat(N40, ")")
97
97
  },
98
98
  warning: {
99
- light: "var(--ds-border-focus, ".concat(N200, ")"),
100
- dark: "var(--ds-border-focus, ".concat(N200, ")")
99
+ light: "var(--ds-border-focused, ".concat(N200, ")"),
100
+ dark: "var(--ds-border-focused, ".concat(N200, ")")
101
101
  }
102
102
  };
103
103
  export var getFlagFocusRingColor = function getFlagFocusRingColor(appearance, mode) {
@@ -106,46 +106,46 @@ export var getFlagFocusRingColor = function getFlagFocusRingColor(appearance, mo
106
106
  var lightButtonBackground = 'rgba(255, 255, 255, 0.08)';
107
107
  var actionBackground = {
108
108
  success: {
109
- light: "var(--ds-background-subtleNeutral-resting, ".concat(lightButtonBackground, ")"),
110
- dark: "var(--ds-background-subtleNeutral-resting, ".concat(N30A, ")")
109
+ light: "var(--ds-background-neutral, ".concat(lightButtonBackground, ")"),
110
+ dark: "var(--ds-background-neutral, ".concat(N30A, ")")
111
111
  },
112
112
  info: {
113
- light: "var(--ds-background-subtleNeutral-resting, ".concat(lightButtonBackground, ")"),
114
- dark: "var(--ds-background-subtleNeutral-resting, ".concat(lightButtonBackground, ")")
113
+ light: "var(--ds-background-neutral, ".concat(lightButtonBackground, ")"),
114
+ dark: "var(--ds-background-neutral, ".concat(lightButtonBackground, ")")
115
115
  },
116
116
  error: {
117
- light: "var(--ds-background-subtleNeutral-resting, ".concat(lightButtonBackground, ")"),
118
- dark: "var(--ds-background-subtleNeutral-resting, ".concat(N30A, ")")
117
+ light: "var(--ds-background-neutral, ".concat(lightButtonBackground, ")"),
118
+ dark: "var(--ds-background-neutral, ".concat(N30A, ")")
119
119
  },
120
120
  warning: {
121
- light: "var(--ds-background-subtleNeutral-resting, ".concat(N30A, ")"),
122
- dark: "var(--ds-background-subtleNeutral-resting, ".concat(N30A, ")")
121
+ light: "var(--ds-background-neutral, ".concat(N30A, ")"),
122
+ dark: "var(--ds-background-neutral, ".concat(N30A, ")")
123
123
  },
124
124
  normal: {
125
- light: "var(--ds-background-subtleNeutral-resting, none)",
126
- dark: "var(--ds-background-subtleNeutral-resting, none)"
125
+ light: "var(--ds-background-neutral, none)",
126
+ dark: "var(--ds-background-neutral, none)"
127
127
  }
128
128
  };
129
129
  var actionColor = {
130
130
  success: {
131
- light: "var(--ds-text-mediumEmphasis, ".concat(N0, ")"),
132
- dark: "var(--ds-text-mediumEmphasis, ".concat(DN40, ")")
131
+ light: "var(--ds-text-subtle, ".concat(N0, ")"),
132
+ dark: "var(--ds-text-subtle, ".concat(DN40, ")")
133
133
  },
134
134
  info: {
135
- light: "var(--ds-text-mediumEmphasis, ".concat(N0, ")"),
136
- dark: "var(--ds-text-mediumEmphasis, ".concat(DN600, ")")
135
+ light: "var(--ds-text-subtle, ".concat(N0, ")"),
136
+ dark: "var(--ds-text-subtle, ".concat(DN600, ")")
137
137
  },
138
138
  error: {
139
- light: "var(--ds-text-mediumEmphasis, ".concat(N0, ")"),
140
- dark: "var(--ds-text-mediumEmphasis, ".concat(DN600, ")")
139
+ light: "var(--ds-text-subtle, ".concat(N0, ")"),
140
+ dark: "var(--ds-text-subtle, ".concat(DN600, ")")
141
141
  },
142
142
  warning: {
143
- light: "var(--ds-text-mediumEmphasis, ".concat(N700, ")"),
144
- dark: "var(--ds-text-mediumEmphasis, ".concat(DN40, ")")
143
+ light: "var(--ds-text-subtle, ".concat(N700, ")"),
144
+ dark: "var(--ds-text-subtle, ".concat(DN40, ")")
145
145
  },
146
146
  normal: {
147
- light: "var(--ds-text-mediumEmphasis, ".concat(B400, ")"),
148
- dark: "var(--ds-text-mediumEmphasis, ".concat(B100, ")")
147
+ light: "var(--ds-text-subtle, ".concat(B400, ")"),
148
+ dark: "var(--ds-text-subtle, ".concat(B100, ")")
149
149
  }
150
150
  };
151
151
  export var getActionBackground = function getActionBackground(appearance, mode) {
@@ -1,5 +1,5 @@
1
1
  {
2
2
  "name": "@atlaskit/flag",
3
- "version": "14.5.1",
3
+ "version": "14.5.4",
4
4
  "sideEffects": false
5
5
  }
@@ -1,8 +1,8 @@
1
1
  /** @jsx jsx */
2
- import { ComponentType } from 'react';
3
- import { CustomThemeButtonProps } from '@atlaskit/button/types';
4
- import { ThemeModes } from '@atlaskit/theme/types';
5
- import { ActionsType, AppearanceTypes } from './types';
2
+ import type { ComponentType } from 'react';
3
+ import type { CustomThemeButtonProps } from '@atlaskit/button/types';
4
+ import type { ThemeModes } from '@atlaskit/theme/types';
5
+ import type { ActionsType, AppearanceTypes } from './types';
6
6
  declare type Props = {
7
7
  appearance: AppearanceTypes;
8
8
  actions: ActionsType;
@@ -1,7 +1,7 @@
1
1
  /** @jsx jsx */
2
2
  import { ReactElement } from 'react';
3
3
  import type { UIAnalyticsEvent } from '@atlaskit/analytics-next';
4
- declare type Props = {
4
+ declare type FlagGroupProps = {
5
5
  /** ID attribute used for DOM selection. */
6
6
  id?: string;
7
7
  /** Describes the specific role of this FlagGroup for users viewing the page with a screen reader (defaults to `Flag notifications`). */
@@ -23,5 +23,5 @@ declare type FlagGroupAPI = {
23
23
  };
24
24
  export declare const FlagGroupContext: import("react").Context<FlagGroupAPI>;
25
25
  export declare function useFlagGroup(): FlagGroupAPI;
26
- declare const FlagGroup: (props: Props) => JSX.Element;
26
+ declare const FlagGroup: (props: FlagGroupProps) => JSX.Element;
27
27
  export default FlagGroup;
@@ -1,4 +1,4 @@
1
1
  /// <reference types="react" />
2
- import { FlagProps } from './types';
2
+ import type { FlagProps } from './types';
3
3
  declare const Flag: (props: FlagProps) => JSX.Element;
4
4
  export default Flag;
@@ -0,0 +1,7 @@
1
+ import { FC } from 'react';
2
+ interface DescriptionProps {
3
+ testId?: string;
4
+ color: string;
5
+ }
6
+ declare const Description: FC<DescriptionProps>;
7
+ export default Description;
@@ -0,0 +1,11 @@
1
+ /// <reference types="react" />
2
+ import { AppearanceTypes } from '../types';
3
+ interface DismissButtonProps {
4
+ appearance: AppearanceTypes;
5
+ onClick: (...args: any) => void;
6
+ isExpanded: boolean;
7
+ isBold: boolean;
8
+ testId?: string;
9
+ }
10
+ declare const _default: import("react").MemoExoticComponent<({ appearance, onClick, isBold, isExpanded, testId, }: DismissButtonProps) => JSX.Element>;
11
+ export default _default;
@@ -0,0 +1,8 @@
1
+ /** @jsx jsx */
2
+ import { FC } from 'react';
3
+ declare type ExpanderProps = {
4
+ isExpanded: boolean;
5
+ testId?: string;
6
+ };
7
+ declare const Expander: FC<ExpanderProps>;
8
+ export default Expander;
@@ -0,0 +1,4 @@
1
+ export { default as Title } from './title';
2
+ export { default as Description } from './description';
3
+ export { default as Expander } from './expander';
4
+ export { default as DismissButton } from './dismiss-button';
@@ -0,0 +1,6 @@
1
+ import { FC } from 'react';
2
+ interface TitleProps {
3
+ color: string;
4
+ }
5
+ declare const Title: FC<TitleProps>;
6
+ export default Title;
@@ -1,7 +1,7 @@
1
1
  import { ThemeModes } from '@atlaskit/theme/types';
2
2
  import { AppearanceTypes } from './types';
3
3
  export declare const getFlagBackgroundColor: (appearance: AppearanceTypes, mode: ThemeModes) => string;
4
- export declare const flagBorderColor: "var(--ds-background-overlay)";
4
+ export declare const flagBorderColor: "var(--ds-surface-overlay)";
5
5
  export declare const getFlagTextColor: (appearance: AppearanceTypes, mode: ThemeModes) => string;
6
6
  export declare const getFlagIconColor: (appearance: AppearanceTypes, mode: ThemeModes) => string;
7
7
  export declare const flagShadowColor = "rgba(9, 30, 66, 0.25)";
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@atlaskit/flag",
3
- "version": "14.5.1",
3
+ "version": "14.5.4",
4
4
  "description": "A flag is used for confirmations, alerts, and acknowledgments that require minimal user interaction, often displayed using a flag group.",
5
5
  "publishConfig": {
6
6
  "registry": "https://registry.npmjs.org/"
@@ -24,12 +24,15 @@
24
24
  },
25
25
  "dependencies": {
26
26
  "@atlaskit/analytics-next": "^8.0.0",
27
- "@atlaskit/button": "^16.0.0",
27
+ "@atlaskit/button": "^16.2.0",
28
+ "@atlaskit/ds-lib": "^1.4.0",
29
+ "@atlaskit/focus-ring": "^1.0.0",
28
30
  "@atlaskit/icon": "^21.10.0",
29
31
  "@atlaskit/motion": "^1.0.0",
30
32
  "@atlaskit/portal": "^4.0.0",
31
33
  "@atlaskit/theme": "^12.1.0",
32
- "@atlaskit/tokens": "^0.5.0",
34
+ "@atlaskit/tokens": "^0.7.0",
35
+ "@atlaskit/visually-hidden": "^1.0.0",
33
36
  "@babel/runtime": "^7.0.0",
34
37
  "@emotion/core": "^10.0.9"
35
38
  },
@@ -71,7 +74,8 @@
71
74
  ],
72
75
  "deprecation": "no-deprecated-imports",
73
76
  "styling": [
74
- "emotion"
77
+ "emotion",
78
+ "static"
75
79
  ]
76
80
  }
77
81
  },
@@ -1,9 +0,0 @@
1
- /** @jsx jsx */
2
- import { ReactNode } from 'react';
3
- declare type Props = {
4
- children: ReactNode;
5
- isExpanded: boolean;
6
- testId?: string;
7
- };
8
- declare const Expander: ({ children, isExpanded, testId }: Props) => JSX.Element;
9
- export default Expander;
@@ -1,7 +0,0 @@
1
- {
2
- "name": "@atlaskit/flag/expander",
3
- "main": "../dist/cjs/expander.js",
4
- "module": "../dist/esm/expander.js",
5
- "module:es2019": "../dist/es2019/expander.js",
6
- "types": "../dist/types/expander.d.ts"
7
- }