@atlaskit/editor-plugin-card 18.2.3 → 18.2.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.
- package/CHANGELOG.md +10 -0
- package/dist/cjs/ui/PasteDisplayAsMenu.compiled.css +0 -1
- package/dist/cjs/ui/PasteDisplayAsMenu.js +5 -2
- package/dist/es2019/ui/PasteDisplayAsMenu.compiled.css +0 -1
- package/dist/es2019/ui/PasteDisplayAsMenu.js +5 -2
- package/dist/esm/ui/PasteDisplayAsMenu.compiled.css +0 -1
- package/dist/esm/ui/PasteDisplayAsMenu.js +5 -2
- package/package.json +2 -2
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,15 @@
|
|
|
1
1
|
# @atlaskit/editor-plugin-card
|
|
2
2
|
|
|
3
|
+
## 18.2.4
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- [`faab2cfa1c720`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/faab2cfa1c720) -
|
|
8
|
+
Fix white corners on the paste "Display as" menu buttons. The button wrapper no longer paints an
|
|
9
|
+
opaque surface background behind the rounded button, so each button's corners now match the sunken
|
|
10
|
+
tray background instead of showing white.
|
|
11
|
+
- Updated dependencies
|
|
12
|
+
|
|
3
13
|
## 18.2.3
|
|
4
14
|
|
|
5
15
|
### Patch Changes
|
|
@@ -18,7 +18,6 @@
|
|
|
18
18
|
._bfhk187o{background-color:var(--ds-background-disabled,#0515240f)}
|
|
19
19
|
._bfhkhfxm{background-color:var(--ds-surface-sunken,#f8f8f8)}
|
|
20
20
|
._bfhksm61{background-color:var(--ds-background-neutral-subtle,#00000000)}
|
|
21
|
-
._bfhkvuon{background-color:var(--ds-surface,#fff)}
|
|
22
21
|
._ca0q1b66{padding-top:var(--ds-space-050,4px)}
|
|
23
22
|
._n3td1b66{padding-bottom:var(--ds-space-050,4px)}
|
|
24
23
|
._otyru2gc{margin-bottom:var(--ds-space-100,8px)}
|
|
@@ -46,7 +46,7 @@ var SMART_LINK_DISPLAY_AS_PASTE_MENU_SECTION_KEY = exports.SMART_LINK_DISPLAY_AS
|
|
|
46
46
|
|
|
47
47
|
var styles = {
|
|
48
48
|
appearanceBox: "_2rko1qi0 _bfhkhfxm _19pku2gc _2hwxu2gc _otyru2gc _18u0u2gc _ca0q1b66 _u5f31b66 _n3td1b66 _19bv1b66",
|
|
49
|
-
iconWrapper: "
|
|
49
|
+
iconWrapper: "_1e0c1txw _1bsb1osq _1bah1b1v",
|
|
50
50
|
iconButton: "_2rko1qi0 _1h6d1l7x _1dqonqa1 _189ee4h9 _4cvr1h6o _syazi7uo _1e0c1txw _4t3izwfg _1bah1h6o _1bsb1osq _bfhksm61 _irr31dpa _1di6fcek",
|
|
51
51
|
iconButtonSelected: "_2rko1qi0 _1h6dq98m _1dqonqa1 _189ee4h9 _4cvr1h6o _bfhk15s3 _syazi7uo _1e0c1txw _4t3izwfg _1bah1h6o _1bsb1osq _irr3ufnl _1di6nozp",
|
|
52
52
|
iconButtonDisabled: "_2rko1qi0 _1h6dbk0g _1dqonqa1 _189ee4h9 _4cvr1h6o _bfhk187o _syaz1gmx _1e0c1txw _4t3izwfg _1bah1h6o _1bsb1osq"
|
|
@@ -197,7 +197,9 @@ var PasteDisplayAsMenuHorizontalView = function PasteDisplayAsMenuHorizontalView
|
|
|
197
197
|
var frameRef = (0, _react.useRef)(null);
|
|
198
198
|
var isApplyingRef = (0, _react.useRef)(false);
|
|
199
199
|
var apiWithPasteOptionsToolbar = api;
|
|
200
|
-
var pasteRange = (0, _hooks.useSharedPluginStateWithSelector)(apiWithPasteOptionsToolbar, ['pasteOptionsToolbarPlugin'],
|
|
200
|
+
var pasteRange = (0, _hooks.useSharedPluginStateWithSelector)(apiWithPasteOptionsToolbar, ['pasteOptionsToolbarPlugin'],
|
|
201
|
+
// @ts-ignore TS7006 - isolated Fast Typecheck can't infer the selector states generic
|
|
202
|
+
function (states) {
|
|
201
203
|
var pluginState = states.pasteOptionsToolbarPluginState;
|
|
202
204
|
return pluginState ? {
|
|
203
205
|
pasteEndPos: pluginState.pasteEndPos,
|
|
@@ -205,6 +207,7 @@ var PasteDisplayAsMenuHorizontalView = function PasteDisplayAsMenuHorizontalView
|
|
|
205
207
|
} : undefined;
|
|
206
208
|
});
|
|
207
209
|
// Subscribe to card state so the menu re-renders when resolved card metadata updates.
|
|
210
|
+
// @ts-ignore TS7006 - isolated Fast Typecheck can't infer the selector states generic
|
|
208
211
|
(0, _hooks.useSharedPluginStateWithSelector)(api, ['card'], function (states) {
|
|
209
212
|
return states.cardState;
|
|
210
213
|
});
|
|
@@ -18,7 +18,6 @@
|
|
|
18
18
|
._bfhk187o{background-color:var(--ds-background-disabled,#0515240f)}
|
|
19
19
|
._bfhkhfxm{background-color:var(--ds-surface-sunken,#f8f8f8)}
|
|
20
20
|
._bfhksm61{background-color:var(--ds-background-neutral-subtle,#00000000)}
|
|
21
|
-
._bfhkvuon{background-color:var(--ds-surface,#fff)}
|
|
22
21
|
._ca0q1b66{padding-top:var(--ds-space-050,4px)}
|
|
23
22
|
._n3td1b66{padding-bottom:var(--ds-space-050,4px)}
|
|
24
23
|
._otyru2gc{margin-bottom:var(--ds-space-100,8px)}
|
|
@@ -35,7 +35,7 @@ export const SMART_LINK_DISPLAY_AS_PASTE_MENU_SECTION_KEY = 'smart-link-display-
|
|
|
35
35
|
|
|
36
36
|
const styles = {
|
|
37
37
|
appearanceBox: "_2rko1qi0 _bfhkhfxm _19pku2gc _2hwxu2gc _otyru2gc _18u0u2gc _ca0q1b66 _u5f31b66 _n3td1b66 _19bv1b66",
|
|
38
|
-
iconWrapper: "
|
|
38
|
+
iconWrapper: "_1e0c1txw _1bsb1osq _1bah1b1v",
|
|
39
39
|
iconButton: "_2rko1qi0 _1h6d1l7x _1dqonqa1 _189ee4h9 _4cvr1h6o _syazi7uo _1e0c1txw _4t3izwfg _1bah1h6o _1bsb1osq _bfhksm61 _irr31dpa _1di6fcek",
|
|
40
40
|
iconButtonSelected: "_2rko1qi0 _1h6dq98m _1dqonqa1 _189ee4h9 _4cvr1h6o _bfhk15s3 _syazi7uo _1e0c1txw _4t3izwfg _1bah1h6o _1bsb1osq _irr3ufnl _1di6nozp",
|
|
41
41
|
iconButtonDisabled: "_2rko1qi0 _1h6dbk0g _1dqonqa1 _189ee4h9 _4cvr1h6o _bfhk187o _syaz1gmx _1e0c1txw _4t3izwfg _1bah1h6o _1bsb1osq"
|
|
@@ -193,7 +193,9 @@ const PasteDisplayAsMenuHorizontalView = ({
|
|
|
193
193
|
const frameRef = useRef(null);
|
|
194
194
|
const isApplyingRef = useRef(false);
|
|
195
195
|
const apiWithPasteOptionsToolbar = api;
|
|
196
|
-
const pasteRange = useSharedPluginStateWithSelector(apiWithPasteOptionsToolbar, ['pasteOptionsToolbarPlugin'],
|
|
196
|
+
const pasteRange = useSharedPluginStateWithSelector(apiWithPasteOptionsToolbar, ['pasteOptionsToolbarPlugin'],
|
|
197
|
+
// @ts-ignore TS7006 - isolated Fast Typecheck can't infer the selector states generic
|
|
198
|
+
states => {
|
|
197
199
|
const pluginState = states.pasteOptionsToolbarPluginState;
|
|
198
200
|
return pluginState ? {
|
|
199
201
|
pasteEndPos: pluginState.pasteEndPos,
|
|
@@ -201,6 +203,7 @@ const PasteDisplayAsMenuHorizontalView = ({
|
|
|
201
203
|
} : undefined;
|
|
202
204
|
});
|
|
203
205
|
// Subscribe to card state so the menu re-renders when resolved card metadata updates.
|
|
206
|
+
// @ts-ignore TS7006 - isolated Fast Typecheck can't infer the selector states generic
|
|
204
207
|
useSharedPluginStateWithSelector(api, ['card'], states => {
|
|
205
208
|
return states.cardState;
|
|
206
209
|
});
|
|
@@ -18,7 +18,6 @@
|
|
|
18
18
|
._bfhk187o{background-color:var(--ds-background-disabled,#0515240f)}
|
|
19
19
|
._bfhkhfxm{background-color:var(--ds-surface-sunken,#f8f8f8)}
|
|
20
20
|
._bfhksm61{background-color:var(--ds-background-neutral-subtle,#00000000)}
|
|
21
|
-
._bfhkvuon{background-color:var(--ds-surface,#fff)}
|
|
22
21
|
._ca0q1b66{padding-top:var(--ds-space-050,4px)}
|
|
23
22
|
._n3td1b66{padding-bottom:var(--ds-space-050,4px)}
|
|
24
23
|
._otyru2gc{margin-bottom:var(--ds-space-100,8px)}
|
|
@@ -37,7 +37,7 @@ export var SMART_LINK_DISPLAY_AS_PASTE_MENU_SECTION_KEY = 'smart-link-display-as
|
|
|
37
37
|
|
|
38
38
|
var styles = {
|
|
39
39
|
appearanceBox: "_2rko1qi0 _bfhkhfxm _19pku2gc _2hwxu2gc _otyru2gc _18u0u2gc _ca0q1b66 _u5f31b66 _n3td1b66 _19bv1b66",
|
|
40
|
-
iconWrapper: "
|
|
40
|
+
iconWrapper: "_1e0c1txw _1bsb1osq _1bah1b1v",
|
|
41
41
|
iconButton: "_2rko1qi0 _1h6d1l7x _1dqonqa1 _189ee4h9 _4cvr1h6o _syazi7uo _1e0c1txw _4t3izwfg _1bah1h6o _1bsb1osq _bfhksm61 _irr31dpa _1di6fcek",
|
|
42
42
|
iconButtonSelected: "_2rko1qi0 _1h6dq98m _1dqonqa1 _189ee4h9 _4cvr1h6o _bfhk15s3 _syazi7uo _1e0c1txw _4t3izwfg _1bah1h6o _1bsb1osq _irr3ufnl _1di6nozp",
|
|
43
43
|
iconButtonDisabled: "_2rko1qi0 _1h6dbk0g _1dqonqa1 _189ee4h9 _4cvr1h6o _bfhk187o _syaz1gmx _1e0c1txw _4t3izwfg _1bah1h6o _1bsb1osq"
|
|
@@ -188,7 +188,9 @@ var PasteDisplayAsMenuHorizontalView = function PasteDisplayAsMenuHorizontalView
|
|
|
188
188
|
var frameRef = useRef(null);
|
|
189
189
|
var isApplyingRef = useRef(false);
|
|
190
190
|
var apiWithPasteOptionsToolbar = api;
|
|
191
|
-
var pasteRange = useSharedPluginStateWithSelector(apiWithPasteOptionsToolbar, ['pasteOptionsToolbarPlugin'],
|
|
191
|
+
var pasteRange = useSharedPluginStateWithSelector(apiWithPasteOptionsToolbar, ['pasteOptionsToolbarPlugin'],
|
|
192
|
+
// @ts-ignore TS7006 - isolated Fast Typecheck can't infer the selector states generic
|
|
193
|
+
function (states) {
|
|
192
194
|
var pluginState = states.pasteOptionsToolbarPluginState;
|
|
193
195
|
return pluginState ? {
|
|
194
196
|
pasteEndPos: pluginState.pasteEndPos,
|
|
@@ -196,6 +198,7 @@ var PasteDisplayAsMenuHorizontalView = function PasteDisplayAsMenuHorizontalView
|
|
|
196
198
|
} : undefined;
|
|
197
199
|
});
|
|
198
200
|
// Subscribe to card state so the menu re-renders when resolved card metadata updates.
|
|
201
|
+
// @ts-ignore TS7006 - isolated Fast Typecheck can't infer the selector states generic
|
|
199
202
|
useSharedPluginStateWithSelector(api, ['card'], function (states) {
|
|
200
203
|
return states.cardState;
|
|
201
204
|
});
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@atlaskit/editor-plugin-card",
|
|
3
|
-
"version": "18.2.
|
|
3
|
+
"version": "18.2.4",
|
|
4
4
|
"description": "Card plugin for @atlaskit/editor-core",
|
|
5
5
|
"author": "Atlassian Pty Ltd",
|
|
6
6
|
"license": "Apache-2.0",
|
|
@@ -59,7 +59,7 @@
|
|
|
59
59
|
"@atlaskit/primitives": "^22.0.0",
|
|
60
60
|
"@atlaskit/prosemirror-history": "^1.0.0",
|
|
61
61
|
"@atlaskit/smart-card": "^45.10.0",
|
|
62
|
-
"@atlaskit/tmp-editor-statsig": "^127.
|
|
62
|
+
"@atlaskit/tmp-editor-statsig": "^127.2.0",
|
|
63
63
|
"@atlaskit/tokens": "^16.0.0",
|
|
64
64
|
"@babel/runtime": "^7.0.0",
|
|
65
65
|
"@emotion/react": "^11.7.1",
|