@atlaskit/editor-plugin-text-color 16.1.3 → 16.1.5

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,17 @@
1
1
  # @atlaskit/editor-plugin-text-color
2
2
 
3
+ ## 16.1.5
4
+
5
+ ### Patch Changes
6
+
7
+ - Updated dependencies
8
+
9
+ ## 16.1.4
10
+
11
+ ### Patch Changes
12
+
13
+ - Updated dependencies
14
+
3
15
  ## 16.1.3
4
16
 
5
17
  ### Patch Changes
@@ -4,11 +4,11 @@ Object.defineProperty(exports, "__esModule", {
4
4
  value: true
5
5
  });
6
6
  exports.getContrastRatio = getContrastRatio;
7
- var _adfSchema = require("@atlaskit/adf-schema");
7
+ var _isHex = require("@atlaskit/adf-schema/is-hex");
8
8
  // from platform/packages/design-system/tokens/src/utils/get-contrast-ratio.tsx
9
9
 
10
10
  function hexToRgb(hex) {
11
- if (!(0, _adfSchema.isHex)(hex)) {
11
+ if (!(0, _isHex.isHex)(hex)) {
12
12
  throw new Error('Invalid HEX');
13
13
  }
14
14
  var colorParts = hex.substring(1).split('');
@@ -26,7 +26,7 @@ function relativeLuminanceW3C(r, g, b) {
26
26
  return 0.2126 * R + 0.7152 * G + 0.0722 * B;
27
27
  }
28
28
  function getContrastRatio(foreground, background) {
29
- if (!(0, _adfSchema.isHex)(foreground) || !(0, _adfSchema.isHex)(background)) {
29
+ if (!(0, _isHex.isHex)(foreground) || !(0, _isHex.isHex)(background)) {
30
30
  throw new Error('Invalid HEX');
31
31
  }
32
32
  var foregroundRgb = hexToRgb(foreground);
@@ -6,7 +6,7 @@ Object.defineProperty(exports, "__esModule", {
6
6
  });
7
7
  exports.textColorPlugin = void 0;
8
8
  var _react = _interopRequireDefault(require("react"));
9
- var _adfSchema = require("@atlaskit/adf-schema");
9
+ var _textColor = require("@atlaskit/adf-schema/text-color");
10
10
  var _fg = require("@atlaskit/platform-feature-flags/fg");
11
11
  var _editorExperiment = require("@atlaskit/tmp-editor-statsig/editor-experiment");
12
12
  var _changeColor2 = require("./editor-commands/change-color");
@@ -69,7 +69,7 @@ var textColorPlugin = exports.textColorPlugin = function textColorPlugin(_ref) {
69
69
  marks: function marks() {
70
70
  return [{
71
71
  name: 'textColor',
72
- mark: _adfSchema.textColor
72
+ mark: _textColor.textColor
73
73
  }];
74
74
  },
75
75
  pmPlugins: function pmPlugins() {
@@ -1,6 +1,6 @@
1
1
  // from platform/packages/design-system/tokens/src/utils/get-contrast-ratio.tsx
2
2
 
3
- import { isHex } from '@atlaskit/adf-schema';
3
+ import { isHex } from '@atlaskit/adf-schema/is-hex';
4
4
  function hexToRgb(hex) {
5
5
  if (!isHex(hex)) {
6
6
  throw new Error('Invalid HEX');
@@ -1,5 +1,5 @@
1
1
  import React from 'react';
2
- import { textColor } from '@atlaskit/adf-schema';
2
+ import { textColor } from '@atlaskit/adf-schema/text-color';
3
3
  import { fg } from '@atlaskit/platform-feature-flags/fg';
4
4
  import { editorExperiment } from '@atlaskit/tmp-editor-statsig/editor-experiment';
5
5
  import { changeColor as changeColorCommand } from './editor-commands/change-color';
@@ -1,6 +1,6 @@
1
1
  // from platform/packages/design-system/tokens/src/utils/get-contrast-ratio.tsx
2
2
 
3
- import { isHex } from '@atlaskit/adf-schema';
3
+ import { isHex } from '@atlaskit/adf-schema/is-hex';
4
4
  function hexToRgb(hex) {
5
5
  if (!isHex(hex)) {
6
6
  throw new Error('Invalid HEX');
@@ -1,5 +1,5 @@
1
1
  import React from 'react';
2
- import { textColor } from '@atlaskit/adf-schema';
2
+ import { textColor } from '@atlaskit/adf-schema/text-color';
3
3
  import { fg } from '@atlaskit/platform-feature-flags/fg';
4
4
  import { editorExperiment } from '@atlaskit/tmp-editor-statsig/editor-experiment';
5
5
  import { changeColor as changeColorCommand } from './editor-commands/change-color';
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@atlaskit/editor-plugin-text-color",
3
- "version": "16.1.3",
3
+ "version": "16.1.5",
4
4
  "description": "Text color plugin for @atlaskit/editor-core",
5
5
  "author": "Atlassian Pty Ltd",
6
6
  "license": "Apache-2.0",
@@ -42,13 +42,13 @@
42
42
  "@atlaskit/platform-feature-flags": "^2.2.0",
43
43
  "@atlaskit/platform-feature-flags-react": "^1.2.0",
44
44
  "@atlaskit/primitives": "^22.5.0",
45
- "@atlaskit/tmp-editor-statsig": "^171.0.0",
45
+ "@atlaskit/tmp-editor-statsig": "^173.0.0",
46
46
  "@atlaskit/tokens": "^16.11.0",
47
47
  "@babel/runtime": "^7.0.0",
48
48
  "@emotion/react": "^11.7.1"
49
49
  },
50
50
  "peerDependencies": {
51
- "@atlaskit/editor-common": "^120.10.0",
51
+ "@atlaskit/editor-common": "^120.11.0",
52
52
  "react": "^18.2.0 || ^19.2.0",
53
53
  "react-dom": "^18.2.0 || ^19.2.0",
54
54
  "react-intl": "^5.25.1 || ^6.0.0 || ^7.0.0"
@@ -61,42 +61,6 @@
61
61
  "react-intl": "^7.0.0",
62
62
  "wait-for-expect": "^1.2.0"
63
63
  },
64
- "techstack": {
65
- "@atlassian/frontend": {
66
- "code-structure": [
67
- "editor-plugin"
68
- ],
69
- "import-structure": [
70
- "atlassian-conventions"
71
- ],
72
- "circular-dependencies": [
73
- "file-and-folder-level"
74
- ]
75
- },
76
- "@repo/internal": {
77
- "dom-events": "use-bind-event-listener",
78
- "analytics": [
79
- "analytics-next"
80
- ],
81
- "design-tokens": [
82
- "color"
83
- ],
84
- "theming": [
85
- "react-context"
86
- ],
87
- "ui-components": [
88
- "lite-mode"
89
- ],
90
- "deprecation": "no-deprecated-imports",
91
- "styling": [
92
- "emotion",
93
- "emotion"
94
- ],
95
- "imports": [
96
- "import-no-extraneous-disable-for-examples-and-docs"
97
- ]
98
- }
99
- },
100
64
  "platform-feature-flags": {
101
65
  "platform_editor_use_preferences_plugin": {
102
66
  "type": "boolean"