@atlaskit/flag 14.5.6 → 14.5.9

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,24 @@
1
1
  # @atlaskit/flag
2
2
 
3
+ ## 14.5.9
4
+
5
+ ### Patch Changes
6
+
7
+ - [`2329b0e8cc0`](https://bitbucket.org/atlassian/atlassian-frontend/commits/2329b0e8cc0) - [ux] DSP-4541 Update wrongly used tokens
8
+
9
+ ## 14.5.8
10
+
11
+ ### Patch Changes
12
+
13
+ - Updated dependencies
14
+
15
+ ## 14.5.7
16
+
17
+ ### Patch Changes
18
+
19
+ - [`cb2392f6d33`](https://bitbucket.org/atlassian/atlassian-frontend/commits/cb2392f6d33) - Upgrade to TypeScript 4.2.4
20
+ - Updated dependencies
21
+
3
22
  ## 14.5.6
4
23
 
5
24
  ### Patch Changes
@@ -3,5 +3,6 @@
3
3
  "main": "../dist/cjs/auto-dismiss-flag.js",
4
4
  "module": "../dist/esm/auto-dismiss-flag.js",
5
5
  "module:es2019": "../dist/es2019/auto-dismiss-flag.js",
6
+ "sideEffects": false,
6
7
  "types": "../dist/types/auto-dismiss-flag.d.ts"
7
8
  }
@@ -3,5 +3,6 @@
3
3
  "main": "../dist/cjs/constants.js",
4
4
  "module": "../dist/esm/constants.js",
5
5
  "module:es2019": "../dist/es2019/constants.js",
6
+ "sideEffects": false,
6
7
  "types": "../dist/types/constants.d.ts"
7
8
  }
@@ -26,7 +26,7 @@ function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "functio
26
26
  function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || _typeof(obj) !== "object" && typeof obj !== "function") { return { default: obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj.default = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
27
27
 
28
28
  var packageName = "@atlaskit/flag";
29
- var packageVersion = "14.5.6";
29
+ var packageVersion = "14.5.9";
30
30
  var AUTO_DISMISS_SECONDS = 8;
31
31
  exports.AUTO_DISMISS_SECONDS = AUTO_DISMISS_SECONDS;
32
32
 
package/dist/cjs/flag.js CHANGED
@@ -44,7 +44,7 @@ function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { va
44
44
  var analyticsAttributes = {
45
45
  componentName: 'flag',
46
46
  packageName: "@atlaskit/flag",
47
- packageVersion: "14.5.6"
47
+ packageVersion: "14.5.9"
48
48
  };
49
49
  var gridSize = (0, _constants.gridSize)();
50
50
  var doubleGridSize = gridSize * 2;
@@ -140,12 +140,14 @@ var Flag = function Flag(props) {
140
140
  onMouseOut: onMouseOut,
141
141
  onBlur: onBlurAnalytics
142
142
  };
143
- var boxShadow = "var(--ds-shadow-overlay, ".concat("0 20px 32px -8px ".concat(_theme.flagShadowColor), ")");
143
+ var boxShadowValue = "0 20px 32px -8px ".concat(_theme.flagShadowColor);
144
144
 
145
145
  if (!isBold) {
146
- boxShadow = "var(--ds-shadow-overlay, ".concat("0 0 1px ".concat(_theme.flagBorderColor, ", ").concat(boxShadow), ")");
146
+ boxShadowValue = "0 0 1px ".concat(_theme.flagBorderColor, ", ").concat(boxShadowValue);
147
147
  }
148
148
 
149
+ var boxShadow = "var(--ds-shadow-overlay, ".concat(boxShadowValue, ")");
150
+
149
151
  var _useGlobalTheme = (0, _components.useGlobalTheme)(),
150
152
  mode = _useGlobalTheme.mode;
151
153
 
package/dist/cjs/theme.js CHANGED
@@ -32,11 +32,18 @@ var flagBackgroundColor = {
32
32
 
33
33
  var getFlagBackgroundColor = function getFlagBackgroundColor(appearance, mode) {
34
34
  return flagBackgroundColor[appearance][mode];
35
- };
35
+ }; // token set in flag.tsx instead
36
+
37
+ /* eslint-disable @atlaskit/design-system/ensure-design-token-usage */
38
+
36
39
 
37
40
  exports.getFlagBackgroundColor = getFlagBackgroundColor;
38
- var flagBorderColor = "var(--ds-surface-overlay, ".concat(_colors.N60A, ")");
41
+ var flagBorderColor = _colors.N60A;
39
42
  exports.flagBorderColor = flagBorderColor;
43
+ var flagShadowColor = _colors.N50A;
44
+ /* eslint-enable @atlaskit/design-system/ensure-design-token-usage */
45
+
46
+ exports.flagShadowColor = flagShadowColor;
40
47
  var flagIconColor = {
41
48
  error: {
42
49
  light: "var(--ds-icon-inverse, ".concat(_colors.N0, ")"),
@@ -90,13 +97,9 @@ exports.getFlagTextColor = getFlagTextColor;
90
97
 
91
98
  var getFlagIconColor = function getFlagIconColor(appearance, mode) {
92
99
  return flagIconColor[appearance][mode];
93
- }; // token set in flag.tsx instead
94
- // eslint-disable-next-line @atlaskit/design-system/ensure-design-token-usage
95
-
100
+ };
96
101
 
97
102
  exports.getFlagIconColor = getFlagIconColor;
98
- var flagShadowColor = _colors.N50A;
99
- exports.flagShadowColor = flagShadowColor;
100
103
  var flagFocusRingColor = {
101
104
  error: {
102
105
  light: "var(--ds-border-focused, ".concat(_colors.N40, ")"),
@@ -1,5 +1,5 @@
1
1
  {
2
2
  "name": "@atlaskit/flag",
3
- "version": "14.5.6",
3
+ "version": "14.5.9",
4
4
  "sideEffects": false
5
5
  }
@@ -5,7 +5,7 @@ import noop from '@atlaskit/ds-lib/noop';
5
5
  import Flag from './flag';
6
6
  import { useFlagGroup } from './flag-group';
7
7
  const packageName = "@atlaskit/flag";
8
- const packageVersion = "14.5.6";
8
+ const packageVersion = "14.5.9";
9
9
  export const AUTO_DISMISS_SECONDS = 8;
10
10
 
11
11
  const AutoDismissFlag = props => {
@@ -16,7 +16,7 @@ import { Title, Description, Expander, DismissButton } from './internal';
16
16
  const analyticsAttributes = {
17
17
  componentName: 'flag',
18
18
  packageName: "@atlaskit/flag",
19
- packageVersion: "14.5.6"
19
+ packageVersion: "14.5.9"
20
20
  };
21
21
  const gridSize = getGridSize();
22
22
  const doubleGridSize = gridSize * 2;
@@ -104,12 +104,13 @@ const Flag = props => {
104
104
  onMouseOut,
105
105
  onBlur: onBlurAnalytics
106
106
  };
107
- let boxShadow = `var(--ds-shadow-overlay, ${`0 20px 32px -8px ${flagShadowColor}`})`;
107
+ let boxShadowValue = `0 20px 32px -8px ${flagShadowColor}`;
108
108
 
109
109
  if (!isBold) {
110
- boxShadow = `var(--ds-shadow-overlay, ${`0 0 1px ${flagBorderColor}, ${boxShadow}`})`;
110
+ boxShadowValue = `0 0 1px ${flagBorderColor}, ${boxShadowValue}`;
111
111
  }
112
112
 
113
+ const boxShadow = `var(--ds-shadow-overlay, ${boxShadowValue})`;
113
114
  const {
114
115
  mode
115
116
  } = useGlobalTheme();
@@ -21,8 +21,14 @@ const flagBackgroundColor = {
21
21
  dark: `var(--ds-background-warning-bold, ${Y300})`
22
22
  }
23
23
  };
24
- export const getFlagBackgroundColor = (appearance, mode) => flagBackgroundColor[appearance][mode];
25
- export const flagBorderColor = `var(--ds-surface-overlay, ${N60A})`;
24
+ export const getFlagBackgroundColor = (appearance, mode) => flagBackgroundColor[appearance][mode]; // token set in flag.tsx instead
25
+
26
+ /* eslint-disable @atlaskit/design-system/ensure-design-token-usage */
27
+
28
+ export const flagBorderColor = N60A;
29
+ export const flagShadowColor = N50A;
30
+ /* eslint-enable @atlaskit/design-system/ensure-design-token-usage */
31
+
26
32
  const flagIconColor = {
27
33
  error: {
28
34
  light: `var(--ds-icon-inverse, ${N0})`,
@@ -68,10 +74,7 @@ const flagTextColor = {
68
74
  }
69
75
  };
70
76
  export const getFlagTextColor = (appearance, mode) => flagTextColor[appearance][mode];
71
- export const getFlagIconColor = (appearance, mode) => flagIconColor[appearance][mode]; // token set in flag.tsx instead
72
- // eslint-disable-next-line @atlaskit/design-system/ensure-design-token-usage
73
-
74
- export const flagShadowColor = N50A;
77
+ export const getFlagIconColor = (appearance, mode) => flagIconColor[appearance][mode];
75
78
  const flagFocusRingColor = {
76
79
  error: {
77
80
  light: `var(--ds-border-focused, ${N40})`,
@@ -1,5 +1,5 @@
1
1
  {
2
2
  "name": "@atlaskit/flag",
3
- "version": "14.5.6",
3
+ "version": "14.5.9",
4
4
  "sideEffects": false
5
5
  }
@@ -5,7 +5,7 @@ import noop from '@atlaskit/ds-lib/noop';
5
5
  import Flag from './flag';
6
6
  import { useFlagGroup } from './flag-group';
7
7
  var packageName = "@atlaskit/flag";
8
- var packageVersion = "14.5.6";
8
+ var packageVersion = "14.5.9";
9
9
  export var AUTO_DISMISS_SECONDS = 8;
10
10
 
11
11
  var AutoDismissFlag = function AutoDismissFlag(props) {
package/dist/esm/flag.js CHANGED
@@ -22,7 +22,7 @@ import { Title, Description, Expander, DismissButton } from './internal';
22
22
  var analyticsAttributes = {
23
23
  componentName: 'flag',
24
24
  packageName: "@atlaskit/flag",
25
- packageVersion: "14.5.6"
25
+ packageVersion: "14.5.9"
26
26
  };
27
27
  var gridSize = getGridSize();
28
28
  var doubleGridSize = gridSize * 2;
@@ -118,12 +118,14 @@ var Flag = function Flag(props) {
118
118
  onMouseOut: onMouseOut,
119
119
  onBlur: onBlurAnalytics
120
120
  };
121
- var boxShadow = "var(--ds-shadow-overlay, ".concat("0 20px 32px -8px ".concat(flagShadowColor), ")");
121
+ var boxShadowValue = "0 20px 32px -8px ".concat(flagShadowColor);
122
122
 
123
123
  if (!isBold) {
124
- boxShadow = "var(--ds-shadow-overlay, ".concat("0 0 1px ".concat(flagBorderColor, ", ").concat(boxShadow), ")");
124
+ boxShadowValue = "0 0 1px ".concat(flagBorderColor, ", ").concat(boxShadowValue);
125
125
  }
126
126
 
127
+ var boxShadow = "var(--ds-shadow-overlay, ".concat(boxShadowValue, ")");
128
+
127
129
  var _useGlobalTheme = useGlobalTheme(),
128
130
  mode = _useGlobalTheme.mode;
129
131
 
package/dist/esm/theme.js CHANGED
@@ -23,8 +23,14 @@ var flagBackgroundColor = {
23
23
  };
24
24
  export var getFlagBackgroundColor = function getFlagBackgroundColor(appearance, mode) {
25
25
  return flagBackgroundColor[appearance][mode];
26
- };
27
- export var flagBorderColor = "var(--ds-surface-overlay, ".concat(N60A, ")");
26
+ }; // token set in flag.tsx instead
27
+
28
+ /* eslint-disable @atlaskit/design-system/ensure-design-token-usage */
29
+
30
+ export var flagBorderColor = N60A;
31
+ export var flagShadowColor = N50A;
32
+ /* eslint-enable @atlaskit/design-system/ensure-design-token-usage */
33
+
28
34
  var flagIconColor = {
29
35
  error: {
30
36
  light: "var(--ds-icon-inverse, ".concat(N0, ")"),
@@ -74,10 +80,7 @@ export var getFlagTextColor = function getFlagTextColor(appearance, mode) {
74
80
  };
75
81
  export var getFlagIconColor = function getFlagIconColor(appearance, mode) {
76
82
  return flagIconColor[appearance][mode];
77
- }; // token set in flag.tsx instead
78
- // eslint-disable-next-line @atlaskit/design-system/ensure-design-token-usage
79
-
80
- export var flagShadowColor = N50A;
83
+ };
81
84
  var flagFocusRingColor = {
82
85
  error: {
83
86
  light: "var(--ds-border-focused, ".concat(N40, ")"),
@@ -1,5 +1,5 @@
1
1
  {
2
2
  "name": "@atlaskit/flag",
3
- "version": "14.5.6",
3
+ "version": "14.5.9",
4
4
  "sideEffects": false
5
5
  }
@@ -1,10 +1,10 @@
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-surface-overlay)";
4
+ export declare const flagBorderColor = "rgba(9, 30, 66, 0.31)";
5
+ export declare const flagShadowColor = "rgba(9, 30, 66, 0.25)";
5
6
  export declare const getFlagTextColor: (appearance: AppearanceTypes, mode: ThemeModes) => string;
6
7
  export declare const getFlagIconColor: (appearance: AppearanceTypes, mode: ThemeModes) => string;
7
- export declare const flagShadowColor = "rgba(9, 30, 66, 0.25)";
8
8
  export declare const getFlagFocusRingColor: (appearance: AppearanceTypes, mode: ThemeModes) => string;
9
9
  export declare const getActionBackground: (appearance: AppearanceTypes, mode: ThemeModes) => string;
10
10
  export declare const getActionColor: (appearance: AppearanceTypes, mode: ThemeModes) => string;
package/flag/package.json CHANGED
@@ -3,5 +3,6 @@
3
3
  "main": "../dist/cjs/flag.js",
4
4
  "module": "../dist/esm/flag.js",
5
5
  "module:es2019": "../dist/es2019/flag.js",
6
+ "sideEffects": false,
6
7
  "types": "../dist/types/flag.d.ts"
7
8
  }
@@ -3,5 +3,6 @@
3
3
  "main": "../dist/cjs/flag-actions.js",
4
4
  "module": "../dist/esm/flag-actions.js",
5
5
  "module:es2019": "../dist/es2019/flag-actions.js",
6
+ "sideEffects": false,
6
7
  "types": "../dist/types/flag-actions.d.ts"
7
8
  }
@@ -3,5 +3,6 @@
3
3
  "main": "../dist/cjs/flag-group.js",
4
4
  "module": "../dist/esm/flag-group.js",
5
5
  "module:es2019": "../dist/es2019/flag-group.js",
6
+ "sideEffects": false,
6
7
  "types": "../dist/types/flag-group.d.ts"
7
8
  }
@@ -3,5 +3,6 @@
3
3
  "main": "../dist/cjs/flag-provider.js",
4
4
  "module": "../dist/esm/flag-provider.js",
5
5
  "module:es2019": "../dist/es2019/flag-provider.js",
6
+ "sideEffects": false,
6
7
  "types": "../dist/types/flag-provider.d.ts"
7
8
  }
package/package.json CHANGED
@@ -1,11 +1,11 @@
1
1
  {
2
2
  "name": "@atlaskit/flag",
3
- "version": "14.5.6",
3
+ "version": "14.5.9",
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/"
7
7
  },
8
- "repository": "https://bitbucket.org/atlassian/atlassian-frontend",
8
+ "repository": "https://bitbucket.org/atlassian/atlassian-frontend-mirror",
9
9
  "author": "Atlassian Pty Ltd",
10
10
  "license": "Apache-2.0",
11
11
  "main": "dist/cjs/index.js",
@@ -24,14 +24,14 @@
24
24
  },
25
25
  "dependencies": {
26
26
  "@atlaskit/analytics-next": "^8.0.0",
27
- "@atlaskit/button": "^16.2.0",
27
+ "@atlaskit/button": "^16.3.0",
28
28
  "@atlaskit/ds-lib": "^1.4.0",
29
29
  "@atlaskit/focus-ring": "^1.0.0",
30
30
  "@atlaskit/icon": "^21.10.0",
31
- "@atlaskit/motion": "^1.0.0",
31
+ "@atlaskit/motion": "^1.1.0",
32
32
  "@atlaskit/portal": "^4.0.0",
33
33
  "@atlaskit/theme": "^12.1.0",
34
- "@atlaskit/tokens": "^0.9.0",
34
+ "@atlaskit/tokens": "^0.10.0",
35
35
  "@atlaskit/visually-hidden": "^1.0.0",
36
36
  "@babel/runtime": "^7.0.0",
37
37
  "@emotion/core": "^10.0.9"
@@ -53,7 +53,7 @@
53
53
  "jest-emotion": "^10.0.32",
54
54
  "react-dom": "^16.8.0",
55
55
  "storybook-addon-performance": "^0.16.0",
56
- "typescript": "3.9.10"
56
+ "typescript": "4.2.4"
57
57
  },
58
58
  "keywords": [
59
59
  "atlaskit",
@@ -3,5 +3,6 @@
3
3
  "main": "../dist/cjs/theme.js",
4
4
  "module": "../dist/esm/theme.js",
5
5
  "module:es2019": "../dist/es2019/theme.js",
6
+ "sideEffects": false,
6
7
  "types": "../dist/types/theme.d.ts"
7
8
  }
@@ -3,5 +3,6 @@
3
3
  "main": "../dist/cjs/types.js",
4
4
  "module": "../dist/esm/types.js",
5
5
  "module:es2019": "../dist/es2019/types.js",
6
+ "sideEffects": false,
6
7
  "types": "../dist/types/types.d.ts"
7
8
  }