@atlaskit/editor-core 98.6.0 → 98.7.0
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 +5 -0
- package/dist/es2015/plugins/floating-toolbar/index.js +8 -7
- package/dist/es2015/plugins/floating-toolbar/index.js.map +1 -1
- package/dist/es2015/plugins/floating-toolbar/types.d.ts +24 -3
- package/dist/es2015/plugins/floating-toolbar/ui/Button.d.ts +3 -1
- package/dist/es2015/plugins/floating-toolbar/ui/Button.js +3 -3
- package/dist/es2015/plugins/floating-toolbar/ui/Button.js.map +1 -1
- package/dist/es2015/plugins/floating-toolbar/ui/Input.d.ts +20 -0
- package/dist/es2015/plugins/floating-toolbar/ui/Input.js +44 -0
- package/dist/es2015/plugins/floating-toolbar/ui/Input.js.map +1 -0
- package/dist/es2015/plugins/floating-toolbar/ui/Toolbar.d.ts +6 -0
- package/dist/es2015/plugins/floating-toolbar/ui/Toolbar.js +9 -3
- package/dist/es2015/plugins/floating-toolbar/ui/Toolbar.js.map +1 -1
- package/dist/es2015/plugins/hyperlink/Toolbar.d.ts +14 -0
- package/dist/es2015/plugins/hyperlink/Toolbar.js +110 -0
- package/dist/es2015/plugins/hyperlink/Toolbar.js.map +1 -0
- package/dist/es2015/plugins/hyperlink/commands.js +3 -0
- package/dist/es2015/plugins/hyperlink/commands.js.map +1 -1
- package/dist/es2015/plugins/hyperlink/index.js +3 -15
- package/dist/es2015/plugins/hyperlink/index.js.map +1 -1
- package/dist/es2015/plugins/hyperlink/ui/{HyperlinkEdit/index.d.ts → RecentSearch/LinkAddToolbar.d.ts} +9 -9
- package/dist/es2015/plugins/hyperlink/ui/RecentSearch/LinkAddToolbar.js +210 -0
- package/dist/es2015/plugins/hyperlink/ui/RecentSearch/LinkAddToolbar.js.map +1 -0
- package/dist/es2015/plugins/hyperlink/ui/RecentSearch/index.d.ts +4 -27
- package/dist/es2015/plugins/hyperlink/ui/RecentSearch/index.js +15 -187
- package/dist/es2015/plugins/hyperlink/ui/RecentSearch/index.js.map +1 -1
- package/dist/es2015/plugins/table/ui/LayoutButton/index.js +1 -1
- package/dist/es2015/plugins/table/ui/LayoutButton/index.js.map +1 -1
- package/dist/es2015/ui/ContentStyles/index.js +1 -1
- package/dist/es2015/ui/ContentStyles/index.js.map +1 -1
- package/dist/es5/plugins/floating-toolbar/index.js +8 -7
- package/dist/es5/plugins/floating-toolbar/index.js.map +1 -1
- package/dist/es5/plugins/floating-toolbar/types.d.ts +24 -3
- package/dist/es5/plugins/floating-toolbar/ui/Button.d.ts +3 -1
- package/dist/es5/plugins/floating-toolbar/ui/Button.js +3 -3
- package/dist/es5/plugins/floating-toolbar/ui/Button.js.map +1 -1
- package/dist/es5/plugins/floating-toolbar/ui/Input.d.ts +20 -0
- package/dist/es5/plugins/floating-toolbar/ui/Input.js +46 -0
- package/dist/es5/plugins/floating-toolbar/ui/Input.js.map +1 -0
- package/dist/es5/plugins/floating-toolbar/ui/Toolbar.d.ts +6 -0
- package/dist/es5/plugins/floating-toolbar/ui/Toolbar.js +9 -3
- package/dist/es5/plugins/floating-toolbar/ui/Toolbar.js.map +1 -1
- package/dist/es5/plugins/hyperlink/Toolbar.d.ts +14 -0
- package/dist/es5/plugins/hyperlink/Toolbar.js +112 -0
- package/dist/es5/plugins/hyperlink/Toolbar.js.map +1 -0
- package/dist/es5/plugins/hyperlink/commands.js +3 -0
- package/dist/es5/plugins/hyperlink/commands.js.map +1 -1
- package/dist/es5/plugins/hyperlink/index.js +2 -14
- package/dist/es5/plugins/hyperlink/index.js.map +1 -1
- package/dist/es5/plugins/hyperlink/ui/{HyperlinkEdit/index.d.ts → RecentSearch/LinkAddToolbar.d.ts} +9 -9
- package/dist/es5/plugins/hyperlink/ui/RecentSearch/LinkAddToolbar.js +212 -0
- package/dist/es5/plugins/hyperlink/ui/RecentSearch/LinkAddToolbar.js.map +1 -0
- package/dist/es5/plugins/hyperlink/ui/RecentSearch/index.d.ts +4 -27
- package/dist/es5/plugins/hyperlink/ui/RecentSearch/index.js +15 -187
- package/dist/es5/plugins/hyperlink/ui/RecentSearch/index.js.map +1 -1
- package/dist/es5/plugins/table/ui/LayoutButton/index.js +1 -1
- package/dist/es5/plugins/table/ui/LayoutButton/index.js.map +1 -1
- package/dist/es5/ui/ContentStyles/index.js +1 -1
- package/dist/es5/ui/ContentStyles/index.js.map +1 -1
- package/dist/package.json +1 -1
- package/package.json +2 -2
- package/dist/es2015/plugins/hyperlink/ui/HyperlinkEdit/index.js +0 -55
- package/dist/es2015/plugins/hyperlink/ui/HyperlinkEdit/index.js.map +0 -1
- package/dist/es2015/plugins/hyperlink/ui/index.d.ts +0 -101
- package/dist/es2015/plugins/hyperlink/ui/index.js +0 -142
- package/dist/es2015/plugins/hyperlink/ui/index.js.map +0 -1
- package/dist/es5/plugins/hyperlink/ui/HyperlinkEdit/index.js +0 -57
- package/dist/es5/plugins/hyperlink/ui/HyperlinkEdit/index.js.map +0 -1
- package/dist/es5/plugins/hyperlink/ui/index.d.ts +0 -101
- package/dist/es5/plugins/hyperlink/ui/index.js +0 -145
- package/dist/es5/plugins/hyperlink/ui/index.js.map +0 -1
|
@@ -0,0 +1,212 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
var tslib_1 = require("tslib");
|
|
4
|
+
var React = require("react");
|
|
5
|
+
var react_1 = require("react");
|
|
6
|
+
var styled_components_1 = require("styled-components");
|
|
7
|
+
var react_intl_1 = require("react-intl");
|
|
8
|
+
var analytics_1 = require("../../../../analytics");
|
|
9
|
+
var PanelTextInput_1 = require("../../../../ui/PanelTextInput");
|
|
10
|
+
var RecentList_1 = require("./RecentList");
|
|
11
|
+
var Container = styled_components_1.default.div(templateObject_2 || (templateObject_2 = tslib_1.__makeTemplateObject(["\n width: 420px;\n display: flex;\n flex-direction: column;\n overflow: auto;\n\n ", ";\n line-height: 2;\n\n input {\n padding: 8px;\n }\n"], ["\n width: 420px;\n display: flex;\n flex-direction: column;\n overflow: auto;\n\n ",
|
|
12
|
+
";\n line-height: 2;\n\n input {\n padding: 8px;\n }\n"])), function (_a) {
|
|
13
|
+
var provider = _a.provider;
|
|
14
|
+
return styled_components_1.css(templateObject_1 || (templateObject_1 = tslib_1.__makeTemplateObject(["\n width: ", "px;\n "], ["\n width: ", "px;\n "])), provider ? '420x' : '360');
|
|
15
|
+
});
|
|
16
|
+
exports.messages = react_intl_1.defineMessages({
|
|
17
|
+
placeholder: {
|
|
18
|
+
id: 'fabric.editor.hyperlinkToolbarPlaceholder',
|
|
19
|
+
defaultMessage: 'Paste link or search recently viewed',
|
|
20
|
+
description: 'Paste link or search recently viewed',
|
|
21
|
+
},
|
|
22
|
+
linkPlaceholder: {
|
|
23
|
+
id: 'fabric.editor.linkPlaceholder',
|
|
24
|
+
defaultMessage: 'Paste link',
|
|
25
|
+
description: 'Create a new link by pasting a URL.',
|
|
26
|
+
},
|
|
27
|
+
});
|
|
28
|
+
var RecentSearch = /** @class */ (function (_super) {
|
|
29
|
+
tslib_1.__extends(RecentSearch, _super);
|
|
30
|
+
function RecentSearch() {
|
|
31
|
+
var _this = _super !== null && _super.apply(this, arguments) || this;
|
|
32
|
+
_this.state = {
|
|
33
|
+
selectedIndex: -1,
|
|
34
|
+
isLoading: false,
|
|
35
|
+
text: '',
|
|
36
|
+
items: [],
|
|
37
|
+
};
|
|
38
|
+
_this.updateInput = function (input) { return tslib_1.__awaiter(_this, void 0, void 0, function () {
|
|
39
|
+
var _a, _b, _c, _d, _e, _f;
|
|
40
|
+
return tslib_1.__generator(this, function (_g) {
|
|
41
|
+
switch (_g.label) {
|
|
42
|
+
case 0:
|
|
43
|
+
this.setState({ text: input });
|
|
44
|
+
if (!this.state.provider) return [3 /*break*/, 4];
|
|
45
|
+
if (!(input.length === 0)) return [3 /*break*/, 2];
|
|
46
|
+
_a = this.setState;
|
|
47
|
+
_b = {};
|
|
48
|
+
_c = limit;
|
|
49
|
+
return [4 /*yield*/, this.state.provider.getRecentItems()];
|
|
50
|
+
case 1:
|
|
51
|
+
_a.apply(this, [(_b.items = _c.apply(void 0, [_g.sent()]),
|
|
52
|
+
_b.selectedIndex = -1,
|
|
53
|
+
_b)]);
|
|
54
|
+
return [3 /*break*/, 4];
|
|
55
|
+
case 2:
|
|
56
|
+
_d = this.setState;
|
|
57
|
+
_e = {};
|
|
58
|
+
_f = limit;
|
|
59
|
+
return [4 /*yield*/, this.state.provider.searchRecent(input)];
|
|
60
|
+
case 3:
|
|
61
|
+
_d.apply(this, [(_e.items = _f.apply(void 0, [_g.sent()]),
|
|
62
|
+
_e.selectedIndex = 0,
|
|
63
|
+
_e)]);
|
|
64
|
+
_g.label = 4;
|
|
65
|
+
case 4: return [2 /*return*/];
|
|
66
|
+
}
|
|
67
|
+
});
|
|
68
|
+
}); };
|
|
69
|
+
_this.handleSelected = function (href, text) {
|
|
70
|
+
if (_this.props.onSubmit) {
|
|
71
|
+
_this.props.onSubmit(href, text);
|
|
72
|
+
_this.trackAutoCompleteAnalyticsEvent('atlassian.editor.format.hyperlink.autocomplete.click');
|
|
73
|
+
}
|
|
74
|
+
};
|
|
75
|
+
_this.handleMouseMove = function (objectId) {
|
|
76
|
+
var items = _this.state.items;
|
|
77
|
+
if (items) {
|
|
78
|
+
var index = findIndex(items, function (item) { return item.objectId === objectId; });
|
|
79
|
+
_this.setState({
|
|
80
|
+
selectedIndex: index,
|
|
81
|
+
});
|
|
82
|
+
}
|
|
83
|
+
};
|
|
84
|
+
_this.handleSubmit = function () {
|
|
85
|
+
var _a = _this.state, items = _a.items, text = _a.text, selectedIndex = _a.selectedIndex;
|
|
86
|
+
// add the link selected in the dropdown if there is one, otherwise submit the value of the input field
|
|
87
|
+
if (items && items.length > 0 && selectedIndex > -1) {
|
|
88
|
+
var item = items[selectedIndex];
|
|
89
|
+
if (_this.props.onSubmit) {
|
|
90
|
+
_this.props.onSubmit(item.url, item.name);
|
|
91
|
+
_this.trackAutoCompleteAnalyticsEvent('atlassian.editor.format.hyperlink.autocomplete.keyboard');
|
|
92
|
+
}
|
|
93
|
+
}
|
|
94
|
+
else if (text && text.length > 0) {
|
|
95
|
+
if (_this.props.onSubmit) {
|
|
96
|
+
_this.props.onSubmit(text);
|
|
97
|
+
_this.trackAutoCompleteAnalyticsEvent('atlassian.editor.format.hyperlink.autocomplete.notselected');
|
|
98
|
+
}
|
|
99
|
+
}
|
|
100
|
+
};
|
|
101
|
+
_this.handleKeyDown = function (e) {
|
|
102
|
+
var _a = _this.state, items = _a.items, selectedIndex = _a.selectedIndex;
|
|
103
|
+
if (!items || !items.length) {
|
|
104
|
+
return;
|
|
105
|
+
}
|
|
106
|
+
if (e.keyCode === 40) {
|
|
107
|
+
// down
|
|
108
|
+
e.preventDefault();
|
|
109
|
+
_this.setState({
|
|
110
|
+
selectedIndex: (selectedIndex + 1) % items.length,
|
|
111
|
+
});
|
|
112
|
+
}
|
|
113
|
+
else if (e.keyCode === 38) {
|
|
114
|
+
// up
|
|
115
|
+
e.preventDefault();
|
|
116
|
+
_this.setState({
|
|
117
|
+
selectedIndex: selectedIndex > 0 ? selectedIndex - 1 : items.length - 1,
|
|
118
|
+
});
|
|
119
|
+
}
|
|
120
|
+
};
|
|
121
|
+
_this.handleBlur = function () {
|
|
122
|
+
if (_this.props.onBlur) {
|
|
123
|
+
_this.props.onBlur(_this.state.text);
|
|
124
|
+
}
|
|
125
|
+
};
|
|
126
|
+
return _this;
|
|
127
|
+
}
|
|
128
|
+
RecentSearch.prototype.resolveProvider = function () {
|
|
129
|
+
return tslib_1.__awaiter(this, void 0, void 0, function () {
|
|
130
|
+
var provider;
|
|
131
|
+
return tslib_1.__generator(this, function (_a) {
|
|
132
|
+
switch (_a.label) {
|
|
133
|
+
case 0: return [4 /*yield*/, this.props.provider];
|
|
134
|
+
case 1:
|
|
135
|
+
provider = _a.sent();
|
|
136
|
+
this.setState({ provider: provider });
|
|
137
|
+
return [2 /*return*/, provider];
|
|
138
|
+
}
|
|
139
|
+
});
|
|
140
|
+
});
|
|
141
|
+
};
|
|
142
|
+
RecentSearch.prototype.componentDidMount = function () {
|
|
143
|
+
return tslib_1.__awaiter(this, void 0, void 0, function () {
|
|
144
|
+
var activityProvider;
|
|
145
|
+
return tslib_1.__generator(this, function (_a) {
|
|
146
|
+
switch (_a.label) {
|
|
147
|
+
case 0:
|
|
148
|
+
if (!this.props.provider) return [3 /*break*/, 2];
|
|
149
|
+
return [4 /*yield*/, this.resolveProvider()];
|
|
150
|
+
case 1:
|
|
151
|
+
activityProvider = _a.sent();
|
|
152
|
+
this.loadRecentItems(activityProvider);
|
|
153
|
+
_a.label = 2;
|
|
154
|
+
case 2: return [2 /*return*/];
|
|
155
|
+
}
|
|
156
|
+
});
|
|
157
|
+
});
|
|
158
|
+
};
|
|
159
|
+
RecentSearch.prototype.loadRecentItems = function (activityProvider) {
|
|
160
|
+
return tslib_1.__awaiter(this, void 0, void 0, function () {
|
|
161
|
+
var _a, _b, _c;
|
|
162
|
+
return tslib_1.__generator(this, function (_d) {
|
|
163
|
+
switch (_d.label) {
|
|
164
|
+
case 0:
|
|
165
|
+
_d.trys.push([0, , 2, 3]);
|
|
166
|
+
this.setState({ isLoading: true });
|
|
167
|
+
_a = this.setState;
|
|
168
|
+
_b = {};
|
|
169
|
+
_c = limit;
|
|
170
|
+
return [4 /*yield*/, activityProvider.getRecentItems()];
|
|
171
|
+
case 1:
|
|
172
|
+
_a.apply(this, [(_b.items = _c.apply(void 0, [_d.sent()]), _b)]);
|
|
173
|
+
return [3 /*break*/, 3];
|
|
174
|
+
case 2:
|
|
175
|
+
this.setState({ isLoading: false });
|
|
176
|
+
return [7 /*endfinally*/];
|
|
177
|
+
case 3: return [2 /*return*/];
|
|
178
|
+
}
|
|
179
|
+
});
|
|
180
|
+
});
|
|
181
|
+
};
|
|
182
|
+
RecentSearch.prototype.render = function () {
|
|
183
|
+
var _a = this.state, items = _a.items, isLoading = _a.isLoading, selectedIndex = _a.selectedIndex;
|
|
184
|
+
var _b = this.props, formatMessage = _b.intl.formatMessage, provider = _b.provider;
|
|
185
|
+
var placeholder = formatMessage(provider ? exports.messages.placeholder : exports.messages.linkPlaceholder);
|
|
186
|
+
return (React.createElement(Container, { provider: !!provider },
|
|
187
|
+
React.createElement(PanelTextInput_1.default, { placeholder: placeholder, autoFocus: true, onSubmit: this.handleSubmit, onChange: this.updateInput, onBlur: this.handleBlur, onCancel: this.handleBlur, onKeyDown: this.handleKeyDown }),
|
|
188
|
+
React.createElement(RecentList_1.default, { items: items, isLoading: isLoading, selectedIndex: selectedIndex, onSelect: this.handleSelected, onMouseMove: this.handleMouseMove })));
|
|
189
|
+
};
|
|
190
|
+
RecentSearch.prototype.trackAutoCompleteAnalyticsEvent = function (name) {
|
|
191
|
+
var numChars = this.state.text ? this.state.text.length : 0;
|
|
192
|
+
analytics_1.analyticsService.trackEvent(name, { numChars: numChars });
|
|
193
|
+
};
|
|
194
|
+
return RecentSearch;
|
|
195
|
+
}(react_1.PureComponent));
|
|
196
|
+
var findIndex = function (array, predicate) {
|
|
197
|
+
var index = -1;
|
|
198
|
+
array.some(function (item, i) {
|
|
199
|
+
if (predicate(item)) {
|
|
200
|
+
index = i;
|
|
201
|
+
return true;
|
|
202
|
+
}
|
|
203
|
+
return false;
|
|
204
|
+
});
|
|
205
|
+
return index;
|
|
206
|
+
};
|
|
207
|
+
var limit = function (items) {
|
|
208
|
+
return items.slice(0, 5);
|
|
209
|
+
};
|
|
210
|
+
exports.default = react_intl_1.injectIntl(RecentSearch);
|
|
211
|
+
var templateObject_1, templateObject_2;
|
|
212
|
+
//# sourceMappingURL=LinkAddToolbar.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"LinkAddToolbar.js","sourceRoot":"","sources":["../../../../../../src/plugins/hyperlink/ui/RecentSearch/LinkAddToolbar.tsx"],"names":[],"mappings":";;;AAAA,6BAA+B;AAC/B,+BAAqD;AACrD,uDAAgD;AAEhD,yCAA2E;AAC3E,mDAAyD;AACz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{ ProviderFactory } from '@atlaskit/editor-common';
|
|
3
3
|
export interface Props {
|
|
4
|
+
providerFactory: ProviderFactory;
|
|
4
5
|
onBlur?: (text: string) => void;
|
|
5
6
|
onSubmit?: (href: string, text?: string) => void;
|
|
6
|
-
target: Node;
|
|
7
|
-
popupsMountPoint?: HTMLElement;
|
|
8
|
-
popupsBoundariesElement?: HTMLElement;
|
|
9
|
-
autoFocus?: boolean;
|
|
10
|
-
placeholder: string;
|
|
11
|
-
activityProvider: Promise<ActivityProvider>;
|
|
12
7
|
}
|
|
13
|
-
export
|
|
14
|
-
activityProvider?: ActivityProvider;
|
|
15
|
-
items: Array<ActivityItem>;
|
|
16
|
-
selectedIndex: number;
|
|
17
|
-
text: string;
|
|
18
|
-
isLoading: boolean;
|
|
19
|
-
}
|
|
20
|
-
export default class RecentSearch extends PureComponent<Props, State> {
|
|
21
|
-
state: State;
|
|
22
|
-
resolveProvider(): Promise<ActivityProvider>;
|
|
23
|
-
componentDidMount(): Promise<void>;
|
|
24
|
-
private loadRecentItems;
|
|
25
|
-
private updateInput;
|
|
8
|
+
export default class HyperlinkAddToolbar extends React.PureComponent<Props, {}> {
|
|
26
9
|
render(): JSX.Element;
|
|
27
|
-
private handleSelected;
|
|
28
|
-
private handleMouseMove;
|
|
29
|
-
private handleSubmit;
|
|
30
|
-
private handleKeyDown;
|
|
31
|
-
private handleBlur;
|
|
32
|
-
private trackAutoCompleteAnalyticsEvent;
|
|
33
10
|
}
|
|
@@ -2,193 +2,21 @@
|
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
var tslib_1 = require("tslib");
|
|
4
4
|
var React = require("react");
|
|
5
|
-
var
|
|
6
|
-
var
|
|
7
|
-
var
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
var FloatingToolbar_1 = require("../../../../ui/FloatingToolbar");
|
|
12
|
-
var Container = styled_components_1.default.span(templateObject_1 || (templateObject_1 = tslib_1.__makeTemplateObject(["\n width: 420px;\n display: flex;\n flex-direction: column;\n overflow: auto;\n"], ["\n width: 420px;\n display: flex;\n flex-direction: column;\n overflow: auto;\n"])));
|
|
13
|
-
var RecentSearch = /** @class */ (function (_super) {
|
|
14
|
-
tslib_1.__extends(RecentSearch, _super);
|
|
15
|
-
function RecentSearch() {
|
|
16
|
-
var _this = _super !== null && _super.apply(this, arguments) || this;
|
|
17
|
-
_this.state = {
|
|
18
|
-
selectedIndex: -1,
|
|
19
|
-
isLoading: false,
|
|
20
|
-
text: '',
|
|
21
|
-
items: [],
|
|
22
|
-
};
|
|
23
|
-
_this.updateInput = function (input) { return tslib_1.__awaiter(_this, void 0, void 0, function () {
|
|
24
|
-
var _a, _b, _c, _d, _e, _f;
|
|
25
|
-
return tslib_1.__generator(this, function (_g) {
|
|
26
|
-
switch (_g.label) {
|
|
27
|
-
case 0:
|
|
28
|
-
this.setState({ text: input });
|
|
29
|
-
if (!this.state.activityProvider) return [3 /*break*/, 4];
|
|
30
|
-
if (!(input.length === 0)) return [3 /*break*/, 2];
|
|
31
|
-
_a = this.setState;
|
|
32
|
-
_b = {};
|
|
33
|
-
_c = limit;
|
|
34
|
-
return [4 /*yield*/, this.state.activityProvider.getRecentItems()];
|
|
35
|
-
case 1:
|
|
36
|
-
_a.apply(this, [(_b.items = _c.apply(void 0, [_g.sent()]),
|
|
37
|
-
_b.selectedIndex = -1,
|
|
38
|
-
_b)]);
|
|
39
|
-
return [3 /*break*/, 4];
|
|
40
|
-
case 2:
|
|
41
|
-
_d = this.setState;
|
|
42
|
-
_e = {};
|
|
43
|
-
_f = limit;
|
|
44
|
-
return [4 /*yield*/, this.state.activityProvider.searchRecent(input)];
|
|
45
|
-
case 3:
|
|
46
|
-
_d.apply(this, [(_e.items = _f.apply(void 0, [_g.sent()]),
|
|
47
|
-
_e.selectedIndex = 0,
|
|
48
|
-
_e)]);
|
|
49
|
-
_g.label = 4;
|
|
50
|
-
case 4: return [2 /*return*/];
|
|
51
|
-
}
|
|
52
|
-
});
|
|
53
|
-
}); };
|
|
54
|
-
_this.handleSelected = function (href, text) {
|
|
55
|
-
if (_this.props.onSubmit) {
|
|
56
|
-
_this.props.onSubmit(href, text);
|
|
57
|
-
_this.trackAutoCompleteAnalyticsEvent('atlassian.editor.format.hyperlink.autocomplete.click');
|
|
58
|
-
}
|
|
59
|
-
};
|
|
60
|
-
_this.handleMouseMove = function (objectId) {
|
|
61
|
-
var items = _this.state.items;
|
|
62
|
-
if (items) {
|
|
63
|
-
var index = findIndex(items, function (item) { return item.objectId === objectId; });
|
|
64
|
-
_this.setState({
|
|
65
|
-
selectedIndex: index,
|
|
66
|
-
});
|
|
67
|
-
}
|
|
68
|
-
};
|
|
69
|
-
_this.handleSubmit = function () {
|
|
70
|
-
var _a = _this.state, items = _a.items, text = _a.text, selectedIndex = _a.selectedIndex;
|
|
71
|
-
// add the link selected in the dropdown if there is one, otherwise submit the value of the input field
|
|
72
|
-
if (items && items.length > 0 && selectedIndex > -1) {
|
|
73
|
-
var item = items[selectedIndex];
|
|
74
|
-
if (_this.props.onSubmit) {
|
|
75
|
-
_this.props.onSubmit(item.url, item.name);
|
|
76
|
-
_this.trackAutoCompleteAnalyticsEvent('atlassian.editor.format.hyperlink.autocomplete.keyboard');
|
|
77
|
-
}
|
|
78
|
-
}
|
|
79
|
-
else if (text && text.length > 0) {
|
|
80
|
-
if (_this.props.onSubmit) {
|
|
81
|
-
_this.props.onSubmit(text);
|
|
82
|
-
_this.trackAutoCompleteAnalyticsEvent('atlassian.editor.format.hyperlink.autocomplete.notselected');
|
|
83
|
-
}
|
|
84
|
-
}
|
|
85
|
-
};
|
|
86
|
-
_this.handleKeyDown = function (e) {
|
|
87
|
-
var _a = _this.state, items = _a.items, selectedIndex = _a.selectedIndex;
|
|
88
|
-
if (!items || !items.length) {
|
|
89
|
-
return;
|
|
90
|
-
}
|
|
91
|
-
if (e.keyCode === 40) {
|
|
92
|
-
// down
|
|
93
|
-
e.preventDefault();
|
|
94
|
-
_this.setState({
|
|
95
|
-
selectedIndex: (selectedIndex + 1) % items.length,
|
|
96
|
-
});
|
|
97
|
-
}
|
|
98
|
-
else if (e.keyCode === 38) {
|
|
99
|
-
// up
|
|
100
|
-
e.preventDefault();
|
|
101
|
-
_this.setState({
|
|
102
|
-
selectedIndex: selectedIndex > 0 ? selectedIndex - 1 : items.length - 1,
|
|
103
|
-
});
|
|
104
|
-
}
|
|
105
|
-
};
|
|
106
|
-
_this.handleBlur = function () {
|
|
107
|
-
if (_this.props.onBlur) {
|
|
108
|
-
_this.props.onBlur(_this.state.text);
|
|
109
|
-
}
|
|
110
|
-
};
|
|
111
|
-
return _this;
|
|
5
|
+
var LinkAddToolbar_1 = require("./LinkAddToolbar");
|
|
6
|
+
var editor_common_1 = require("@atlaskit/editor-common");
|
|
7
|
+
var HyperlinkAddToolbar = /** @class */ (function (_super) {
|
|
8
|
+
tslib_1.__extends(HyperlinkAddToolbar, _super);
|
|
9
|
+
function HyperlinkAddToolbar() {
|
|
10
|
+
return _super !== null && _super.apply(this, arguments) || this;
|
|
112
11
|
}
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
case 1:
|
|
120
|
-
activityProvider = _a.sent();
|
|
121
|
-
this.setState({ activityProvider: activityProvider });
|
|
122
|
-
return [2 /*return*/, activityProvider];
|
|
123
|
-
}
|
|
124
|
-
});
|
|
125
|
-
});
|
|
12
|
+
HyperlinkAddToolbar.prototype.render = function () {
|
|
13
|
+
var _a = this.props, onSubmit = _a.onSubmit, onBlur = _a.onBlur;
|
|
14
|
+
return (React.createElement(editor_common_1.WithProviders, { providers: ['activityProvider'], providerFactory: this.props.providerFactory, renderNode: function (_a) {
|
|
15
|
+
var activityProvider = _a.activityProvider;
|
|
16
|
+
return (React.createElement(LinkAddToolbar_1.default, { provider: activityProvider, onSubmit: onSubmit, onBlur: onBlur }));
|
|
17
|
+
} }));
|
|
126
18
|
};
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
return tslib_1.__generator(this, function (_a) {
|
|
131
|
-
switch (_a.label) {
|
|
132
|
-
case 0: return [4 /*yield*/, this.resolveProvider()];
|
|
133
|
-
case 1:
|
|
134
|
-
activityProvider = _a.sent();
|
|
135
|
-
this.loadRecentItems(activityProvider);
|
|
136
|
-
return [2 /*return*/];
|
|
137
|
-
}
|
|
138
|
-
});
|
|
139
|
-
});
|
|
140
|
-
};
|
|
141
|
-
RecentSearch.prototype.loadRecentItems = function (activityProvider) {
|
|
142
|
-
return tslib_1.__awaiter(this, void 0, void 0, function () {
|
|
143
|
-
var _a, _b, _c;
|
|
144
|
-
return tslib_1.__generator(this, function (_d) {
|
|
145
|
-
switch (_d.label) {
|
|
146
|
-
case 0:
|
|
147
|
-
_d.trys.push([0, , 2, 3]);
|
|
148
|
-
this.setState({ isLoading: true });
|
|
149
|
-
_a = this.setState;
|
|
150
|
-
_b = {};
|
|
151
|
-
_c = limit;
|
|
152
|
-
return [4 /*yield*/, activityProvider.getRecentItems()];
|
|
153
|
-
case 1:
|
|
154
|
-
_a.apply(this, [(_b.items = _c.apply(void 0, [_d.sent()]), _b)]);
|
|
155
|
-
return [3 /*break*/, 3];
|
|
156
|
-
case 2:
|
|
157
|
-
this.setState({ isLoading: false });
|
|
158
|
-
return [7 /*endfinally*/];
|
|
159
|
-
case 3: return [2 /*return*/];
|
|
160
|
-
}
|
|
161
|
-
});
|
|
162
|
-
});
|
|
163
|
-
};
|
|
164
|
-
RecentSearch.prototype.render = function () {
|
|
165
|
-
var _a = this.props, target = _a.target, popupsMountPoint = _a.popupsMountPoint, popupsBoundariesElement = _a.popupsBoundariesElement, placeholder = _a.placeholder;
|
|
166
|
-
var _b = this.state, items = _b.items, isLoading = _b.isLoading, selectedIndex = _b.selectedIndex;
|
|
167
|
-
return (React.createElement(styles_1.FloatingToolbar, { target: FloatingToolbar_1.getNearestNonTextNode(target), popupsMountPoint: popupsMountPoint, popupsBoundariesElement: popupsBoundariesElement, fitWidth: 420, fitHeight: 350, zIndex: 500, offset: [0, 12], className: "recent-search" },
|
|
168
|
-
React.createElement(Container, null,
|
|
169
|
-
React.createElement(PanelTextInput_1.default, { placeholder: placeholder, autoFocus: true, onSubmit: this.handleSubmit, onChange: this.updateInput, onBlur: this.handleBlur, onCancel: this.handleBlur, onKeyDown: this.handleKeyDown }),
|
|
170
|
-
React.createElement(RecentList_1.default, { items: items, isLoading: isLoading, selectedIndex: selectedIndex, onSelect: this.handleSelected, onMouseMove: this.handleMouseMove }))));
|
|
171
|
-
};
|
|
172
|
-
RecentSearch.prototype.trackAutoCompleteAnalyticsEvent = function (name) {
|
|
173
|
-
var numChars = this.state.text ? this.state.text.length : 0;
|
|
174
|
-
analytics_1.analyticsService.trackEvent(name, { numChars: numChars });
|
|
175
|
-
};
|
|
176
|
-
return RecentSearch;
|
|
177
|
-
}(react_1.PureComponent));
|
|
178
|
-
exports.default = RecentSearch;
|
|
179
|
-
var findIndex = function (array, predicate) {
|
|
180
|
-
var index = -1;
|
|
181
|
-
array.some(function (item, i) {
|
|
182
|
-
if (predicate(item)) {
|
|
183
|
-
index = i;
|
|
184
|
-
return true;
|
|
185
|
-
}
|
|
186
|
-
return false;
|
|
187
|
-
});
|
|
188
|
-
return index;
|
|
189
|
-
};
|
|
190
|
-
var limit = function (items) {
|
|
191
|
-
return items.slice(0, 5);
|
|
192
|
-
};
|
|
193
|
-
var templateObject_1;
|
|
19
|
+
return HyperlinkAddToolbar;
|
|
20
|
+
}(React.PureComponent));
|
|
21
|
+
exports.default = HyperlinkAddToolbar;
|
|
194
22
|
//# sourceMappingURL=index.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../../src/plugins/hyperlink/ui/RecentSearch/index.tsx"],"names":[],"mappings":";;;AAAA,6BAA+B;AAC/B
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../../src/plugins/hyperlink/ui/RecentSearch/index.tsx"],"names":[],"mappings":";;;AAAA,6BAA+B;AAC/B,mDAA0C;AAC1C,yDAAyE;AAQzE;IAAiD,+CAGhD;IAHD;;IAoBA,CAAC;IAhBC,oCAAM,GAAN;QACQ,IAAA,eAAiC,EAA/B,sBAAQ,EAAE,kBAAqB,CAAC;QACxC,OAAO,CACL,oBAAC,6BAAa,IACZ,SAAS,EAAE,CAAC,kBAAkB,CAAC,EAC/B,eAAe,EAAE,IAAI,CAAC,KAAK,CAAC,eAAe,EAC3C,UAAU,EAAE,UAAC,EAAoB;oBAAlB,sCAAgB;gBAAO,OAAA,CACpC,oBAAC,wBAAU,IACT,QAAQ,EAAE,gBAAgB,EAC1B,QAAQ,EAAE,QAAQ,EAClB,MAAM,EAAE,MAAM,GACd,CACH;YANqC,CAMrC,GACD,CACH,CAAC;IACJ,CAAC;IACH,0BAAC;AAAD,CAAC,AApBD,CAAiD,KAAK,CAAC,aAAa,GAoBnE"}
|
|
@@ -49,7 +49,7 @@ var LayoutButton = /** @class */ (function (_super) {
|
|
|
49
49
|
}
|
|
50
50
|
var layout = table.node.attrs.layout;
|
|
51
51
|
var title = formatMessage(getTitle(layout));
|
|
52
|
-
return (React.createElement(editor_common_1.Popup, { ariaLabel: title, offset: POPUP_OFFSET, target: targetRef, alignY: "top", alignX: "right", stick: true, mountTo: mountPoint, boundariesElement: boundariesElement, scrollableElement: scrollableElement },
|
|
52
|
+
return (React.createElement(editor_common_1.Popup, { ariaLabel: title, offset: POPUP_OFFSET, target: targetRef, alignY: "top", alignX: "right", stick: true, mountTo: mountPoint, boundariesElement: boundariesElement, scrollableElement: scrollableElement, forcePlacement: true },
|
|
53
53
|
React.createElement("div", { className: classnames(types_1.TableCssClassName.LAYOUT_BUTTON, (_a = {},
|
|
54
54
|
_a[types_1.TableCssClassName.IS_RESIZING] = isResizing,
|
|
55
55
|
_a)) },
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../../src/plugins/table/ui/LayoutButton/index.tsx"],"names":[],"mappings":";;;AAAA,6BAA+B;AAC/B,yCAA2D;AAC3D,uCAAyC;AAEzC,uDAA8C;AAE9C,yDAAgE;AAChE,6DAA4D;AAC5D,iEAAgE;AAEhE,iDAAkD;AAClD,8DAAyD;AACzD,qCAA6D;AAC7D,yCAAkD;AAClD,oCAA6C;AAW7C,IAAM,YAAY,GAAG;IACnB,CAAC,yBAAgB,GAAG,CAAC;IACrB,CAAC,yBAAgB,GAAG,8BAAc,GAAG,CAAC;CACvC,CAAC;AAEF,IAAM,QAAQ,GAAG,UAAC,MAAmB;IACnC,QAAQ,MAAM,EAAE;QACd,KAAK,SAAS;YACZ,OAAO,kBAAc,CAAC,UAAU,CAAC;QACnC,KAAK,MAAM;YACT,OAAO,kBAAc,CAAC,eAAe,CAAC;QACxC;YACE,OAAO,kBAAc,CAAC,gBAAgB,CAAC;KAC1C;AACH,CAAC,CAAC;AAEF;IAA2B,wCAA+C;IAA1E;QAAA,
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../../src/plugins/table/ui/LayoutButton/index.tsx"],"names":[],"mappings":";;;AAAA,6BAA+B;AAC/B,yCAA2D;AAC3D,uCAAyC;AAEzC,uDAA8C;AAE9C,yDAAgE;AAChE,6DAA4D;AAC5D,iEAAgE;AAEhE,iDAAkD;AAClD,8DAAyD;AACzD,qCAA6D;AAC7D,yCAAkD;AAClD,oCAA6C;AAW7C,IAAM,YAAY,GAAG;IACnB,CAAC,yBAAgB,GAAG,CAAC;IACrB,CAAC,yBAAgB,GAAG,8BAAc,GAAG,CAAC;CACvC,CAAC;AAEF,IAAM,QAAQ,GAAG,UAAC,MAAmB;IACnC,QAAQ,MAAM,EAAE;QACd,KAAK,SAAS;YACZ,OAAO,kBAAc,CAAC,UAAU,CAAC;QACnC,KAAK,MAAM;YACT,OAAO,kBAAc,CAAC,eAAe,CAAC;QACxC;YACE,OAAO,kBAAc,CAAC,gBAAgB,CAAC;KAC1C;A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,CAAC,CAAC,CACF,oBAAC,gBAAU,IAAC,KAAK,EAAE,KAAK,GAAI,CAC7B,GAEH,CACE,CACA,CACT,CAAC;IACJ,CAAC;IAMH,mBAAC;AAAD,CAAC,AA3DD,CAA2B,KAAK,CAAC,SAAS,GA2DzC;AAED,kBAAe,uBAAU,CAAC,YAAY,CAAC,CAAC"}
|
|
@@ -21,7 +21,7 @@ var styles_15 = require("../../plugins/placeholder-text/styles");
|
|
|
21
21
|
var styles_16 = require("../../plugins/tasks-and-decisions/ui/styles");
|
|
22
22
|
var styles_17 = require("../../plugins/grid/styles");
|
|
23
23
|
var styles_18 = require("../../plugins/hyperlink/styles");
|
|
24
|
-
var ContentStyles = styled_components_1.default.div(templateObject_1 || (templateObject_1 = tslib_1.__makeTemplateObject(["\n /* Hack for ie11 that is being used in code block.\n * https://bitbucket.org/atlassian/atlaskit/src/ad09f6361109ece1aab316c8cbd8116ffb7963ef/packages/editor-core/src/schema/nodes/code-block.ts?fileviewer=file-view-default#code-block.ts-110\n */\n & .ie11 {\n overflow: visible;\n word-wrap: break-word;\n }\n\n .ProseMirror {\n word-wrap: break-word;\n white-space: pre-wrap;\n outline: none;\n font-size: ", "px;\n\n ", ";\n ", "\n }\n\n .ProseMirror-hideselection *::selection {\n background: transparent;\n }\n\n .ProseMirror-hideselection *::-moz-selection {\n background: transparent;\n }\n\n .ProseMirror-selectednode {\n outline: none;\n }\n\n .ProseMirror-selectednode:empty {\n outline: 2px solid #8cf;\n }\n\n .inlineCardView-content-wrap {\n display: inline-block;\n max-width: calc(100% - 20px);\n vertical-align: top;\n word-break: break-all;\n }\n\n .blockCardView-content-wrap {\n display: inline-block;\n }\n\n /* fix cursor alignment */\n .ProseMirror .emoji-common-node {\n display: inline;\n vertical-align: baseline;\n\n img {\n display: inline-block;\n vertical-align: middle;\n }\n }\n\n ", "\n ", "\n ", "\n ", "\n ", "\n ", "\n ", "\n ", "\n ", "\n ", "\n ", ";\n ", ";\n ", "\n ", "\n ", "\n ", "\n ", "\n ", "\n ", "\n\n .panelView-content-wrap {\n box-sizing: border-box;\n }\n\n .mediaGroupView-content-wrap ul {\n padding: 0;\n }\n\n /** Needed to override any cleared floats, e.g. image wrapping */\n div.fabric-editor-block-mark[class^='fabric-editor-align'] {\n clear: none !important;\n }\n\n .fabric-editor-align-end {\n text-align: right;\n }\n\n .fabric-editor-align-start {\n text-align: left;\n }\n\n .fabric-editor-align-center {\n text-align: center;\n }\n\n"], ["\n /* Hack for ie11 that is being used in code block.\n * https://bitbucket.org/atlassian/atlaskit/src/ad09f6361109ece1aab316c8cbd8116ffb7963ef/packages/editor-core/src/schema/nodes/code-block.ts?fileviewer=file-view-default#code-block.ts-110\n */\n & .ie11 {\n overflow: visible;\n word-wrap: break-word;\n }\n\n .ProseMirror {\n word-wrap: break-word;\n white-space: pre-wrap;\n outline: none;\n font-size: ", "px;\n\n ", ";\n ", "\n }\n\n .ProseMirror-hideselection *::selection {\n background: transparent;\n }\n\n .ProseMirror-hideselection *::-moz-selection {\n background: transparent;\n }\n\n .ProseMirror-selectednode {\n outline: none;\n }\n\n .ProseMirror-selectednode:empty {\n outline: 2px solid #8cf;\n }\n\n .inlineCardView-content-wrap {\n display: inline-block;\n max-width: calc(100% - 20px);\n vertical-align: top;\n word-break: break-all;\n }\n\n .blockCardView-content-wrap {\n display: inline-block;\n }\n\n /* fix cursor alignment */\n .ProseMirror .emoji-common-node {\n display: inline;\n vertical-align: baseline;\n\n img {\n display: inline-block;\n vertical-align: middle;\n }\n }\n\n ", "\n ", "\n ", "\n ", "\n ", "\n ", "\n ", "\n ", "\n ", "\n ", "\n ", ";\n ", ";\n ", "\n ", "\n ", "\n ", "\n ", "\n ", "\n ", "\n\n .panelView-content-wrap {\n box-sizing: border-box;\n }\n\n .mediaGroupView-content-wrap ul {\n padding: 0;\n }\n\n /** Needed to override any cleared floats, e.g. image wrapping */\n div.fabric-editor-block-mark[class^='fabric-editor-align'] {\n clear: none !important;\n }\n\n .fabric-editor-align-end {\n text-align: right;\n }\n\n .fabric-editor-align-start {\n text-align: left;\n }\n\n .fabric-editor-align-center {\n text-align: center;\n }\n\n"])), editor_common_1.editorFontSize, editor_common_1.paragraphSharedStyles, editor_common_1.indentationSharedStyles, styles_5.blocktypeStyles, styles_14.textFormattingStyles, styles_15.placeholderTextStyles, styles_4.placeholderStyles, styles_6.codeBlockStyles, styles_7.listsStyles, styles_8.ruleStyles, styles_9.mediaStyles, styles_10.layoutStyles, styles_1.telepointerStyle, styles_2.gapCursorStyles, styles_3.tableStyles, styles_11.panelStyles, styles_12.fakeCursorStyles, styles_13.mentionsStyles, styles_16.tasksAndDecisionsStyles, styles_17.gridStyles, styles_18.linkStyles, editor_common_1.blockMarksSharedStyles);
|
|
24
|
+
var ContentStyles = styled_components_1.default.div(templateObject_1 || (templateObject_1 = tslib_1.__makeTemplateObject(["\n /* Hack for ie11 that is being used in code block.\n * https://bitbucket.org/atlassian/atlaskit/src/ad09f6361109ece1aab316c8cbd8116ffb7963ef/packages/editor-core/src/schema/nodes/code-block.ts?fileviewer=file-view-default#code-block.ts-110\n */\n & .ie11 {\n overflow: visible;\n word-wrap: break-word;\n }\n\n .ProseMirror {\n word-wrap: break-word;\n white-space: pre-wrap;\n outline: none;\n font-size: ", "px;\n\n ", ";\n ", "\n }\n\n .ProseMirror-hideselection *::selection {\n background: transparent;\n }\n\n .ProseMirror-hideselection *::-moz-selection {\n background: transparent;\n }\n\n .ProseMirror-selectednode {\n outline: none;\n }\n\n .ProseMirror-selectednode:empty {\n outline: 2px solid #8cf;\n }\n\n .inlineCardView-content-wrap {\n display: inline-block;\n max-width: calc(100% - 20px);\n vertical-align: top;\n word-break: break-all;\n }\n\n .blockCardView-content-wrap {\n display: inline-block;\n }\n\n /* fix cursor alignment */\n .ProseMirror .emoji-common-node {\n display: inline;\n vertical-align: baseline;\n\n img {\n display: inline-block;\n vertical-align: middle;\n }\n }\n\n ", "\n ", "\n ", "\n ", "\n ", "\n ", "\n ", "\n ", "\n ", "\n ", "\n ", ";\n ", ";\n ", "\n ", "\n ", "\n ", "\n ", "\n ", "\n ", "\n\n .panelView-content-wrap {\n box-sizing: border-box;\n }\n\n .mediaGroupView-content-wrap ul {\n padding: 0;\n }\n\n /** Needed to override any cleared floats, e.g. image wrapping */\n div.fabric-editor-block-mark[class^='fabric-editor-align'] {\n clear: none !important;\n }\n\n .fabric-editor-align-end {\n text-align: right;\n }\n\n .fabric-editor-align-start {\n text-align: left;\n }\n\n .fabric-editor-align-center {\n text-align: center;\n }\n\n .hyperlink-floating-toolbar {\n padding: 0;\n }\n\n"], ["\n /* Hack for ie11 that is being used in code block.\n * https://bitbucket.org/atlassian/atlaskit/src/ad09f6361109ece1aab316c8cbd8116ffb7963ef/packages/editor-core/src/schema/nodes/code-block.ts?fileviewer=file-view-default#code-block.ts-110\n */\n & .ie11 {\n overflow: visible;\n word-wrap: break-word;\n }\n\n .ProseMirror {\n word-wrap: break-word;\n white-space: pre-wrap;\n outline: none;\n font-size: ", "px;\n\n ", ";\n ", "\n }\n\n .ProseMirror-hideselection *::selection {\n background: transparent;\n }\n\n .ProseMirror-hideselection *::-moz-selection {\n background: transparent;\n }\n\n .ProseMirror-selectednode {\n outline: none;\n }\n\n .ProseMirror-selectednode:empty {\n outline: 2px solid #8cf;\n }\n\n .inlineCardView-content-wrap {\n display: inline-block;\n max-width: calc(100% - 20px);\n vertical-align: top;\n word-break: break-all;\n }\n\n .blockCardView-content-wrap {\n display: inline-block;\n }\n\n /* fix cursor alignment */\n .ProseMirror .emoji-common-node {\n display: inline;\n vertical-align: baseline;\n\n img {\n display: inline-block;\n vertical-align: middle;\n }\n }\n\n ", "\n ", "\n ", "\n ", "\n ", "\n ", "\n ", "\n ", "\n ", "\n ", "\n ", ";\n ", ";\n ", "\n ", "\n ", "\n ", "\n ", "\n ", "\n ", "\n\n .panelView-content-wrap {\n box-sizing: border-box;\n }\n\n .mediaGroupView-content-wrap ul {\n padding: 0;\n }\n\n /** Needed to override any cleared floats, e.g. image wrapping */\n div.fabric-editor-block-mark[class^='fabric-editor-align'] {\n clear: none !important;\n }\n\n .fabric-editor-align-end {\n text-align: right;\n }\n\n .fabric-editor-align-start {\n text-align: left;\n }\n\n .fabric-editor-align-center {\n text-align: center;\n }\n\n .hyperlink-floating-toolbar {\n padding: 0;\n }\n\n"])), editor_common_1.editorFontSize, editor_common_1.paragraphSharedStyles, editor_common_1.indentationSharedStyles, styles_5.blocktypeStyles, styles_14.textFormattingStyles, styles_15.placeholderTextStyles, styles_4.placeholderStyles, styles_6.codeBlockStyles, styles_7.listsStyles, styles_8.ruleStyles, styles_9.mediaStyles, styles_10.layoutStyles, styles_1.telepointerStyle, styles_2.gapCursorStyles, styles_3.tableStyles, styles_11.panelStyles, styles_12.fakeCursorStyles, styles_13.mentionsStyles, styles_16.tasksAndDecisionsStyles, styles_17.gridStyles, styles_18.linkStyles, editor_common_1.blockMarksSharedStyles);
|
|
25
25
|
exports.default = ContentStyles;
|
|
26
26
|
var templateObject_1;
|
|
27
27
|
//# sourceMappingURL=index.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/ui/ContentStyles/index.ts"],"names":[],"mappings":";;;AAAA,uDAAuC;AAEvC,yDAKiC;AACjC,2DAAoE;AACpE,0DAAkE;AAClE,wDAA4D;AAC5D,2DAAqE;AACrE,0DAAkE;AAClE,0DAAkE;AAClE,qDAAyD;AACzD,oDAAuD;AACvD,qDAAyD;AACzD,uDAA2D;AAC3D,sDAAyD;AACzD,iEAAyE;AACzE,yDAA+D;AAC/D,gEAA4E;AAC5E,iEAA8E;AAC9E,uEAAsF;AACtF,qDAAuD;AACvD,0DAA4D;AAE5D,IAAM,aAAa,GAEf,2BAAM,CAAC,GAAG,
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/ui/ContentStyles/index.ts"],"names":[],"mappings":";;;AAAA,uDAAuC;AAEvC,yDAKiC;AACjC,2DAAoE;AACpE,0DAAkE;AAClE,wDAA4D;AAC5D,2DAAqE;AACrE,0DAAkE;AAClE,0DAAkE;AAClE,qDAAyD;AACzD,oDAAuD;AACvD,qDAAyD;AACzD,uDAA2D;AAC3D,sDAAyD;AACzD,iEAAyE;AACzE,yDAA+D;AAC/D,gEAA4E;AAC5E,iEAA8E;AAC9E,uEAAsF;AACtF,qDAAuD;AACvD,0DAA4D;AAE5D,IAAM,aAAa,GAEf,2BAAM,CAAC,GAAG,87DAAA,qbAaG,EAAc,aAEzB,EAAqB,SACrB,EAAuB,4uBAyCzB,EAAe,MACf,EAAoB,MACpB,EAAqB,MACrB,EAAiB,MACjB,EAAe,MACf,EAAW,MACX,EAAU,MACV,EAAW,MACX,EAAY,MACZ,EAAgB,MAChB,EAAe,OACf,EAAW,OACX,EAAW,MACX,EAAgB,MAChB,EAAc,MACd,EAAuB,MACvB,EAAU,MACV,EAAU,MACV,EAAsB,kiBA+BzB,KA7FgB,8BAAc,EAEzB,qCAAqB,EACrB,uCAAuB,EAyCzB,wBAAe,EACf,8BAAoB,EACpB,+BAAqB,EACrB,0BAAiB,EACjB,wBAAe,EACf,oBAAW,EACX,mBAAU,EACV,oBAAW,EACX,sBAAY,EACZ,yBAAgB,EAChB,wBAAe,EACf,oBAAW,EACX,qBAAW,EACX,0BAAgB,EAChB,wBAAc,EACd,iCAAuB,EACvB,oBAAU,EACV,oBAAU,EACV,sCAAsB,CA+BzB,CAAC;AAEF,kBAAe,aAAa,CAAC"}
|
package/dist/package.json
CHANGED
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@atlaskit/editor-core",
|
|
3
|
-
"version": "98.
|
|
3
|
+
"version": "98.7.0",
|
|
4
4
|
"description": "A package contains Atlassian editor core functionality",
|
|
5
5
|
"license": "Apache-2.0",
|
|
6
6
|
"main": "dist/es5/index.js",
|
|
@@ -38,7 +38,7 @@
|
|
|
38
38
|
"@atlaskit/code": "^8.2.2",
|
|
39
39
|
"@atlaskit/date": "^0.2.0",
|
|
40
40
|
"@atlaskit/droplist": "^7.0.18",
|
|
41
|
-
"@atlaskit/editor-common": "^31.0.
|
|
41
|
+
"@atlaskit/editor-common": "^31.0.4",
|
|
42
42
|
"@atlaskit/editor-json-transformer": "^4.1.9",
|
|
43
43
|
"@atlaskit/editor-markdown-transformer": "^2.1.9",
|
|
44
44
|
"@atlaskit/emoji": "^54.0.0",
|
|
@@ -1,55 +0,0 @@
|
|
|
1
|
-
import * as tslib_1 from "tslib";
|
|
2
|
-
import * as React from 'react';
|
|
3
|
-
import { defineMessages, injectIntl } from 'react-intl';
|
|
4
|
-
import OpenIcon from '@atlaskit/icon/glyph/editor/open';
|
|
5
|
-
import UnlinkIcon from '@atlaskit/icon/glyph/editor/unlink';
|
|
6
|
-
import { akEditorFloatingDialogZIndex } from '@atlaskit/editor-common';
|
|
7
|
-
import PanelTextInput from '../../../../ui/PanelTextInput';
|
|
8
|
-
import { getNearestNonTextNode } from '../../../../ui/FloatingToolbar';
|
|
9
|
-
import { FloatingToolbar, Separator, ToolbarButton } from '../styles';
|
|
10
|
-
export var messages = defineMessages({
|
|
11
|
-
openLink: {
|
|
12
|
-
id: 'fabric.editor.openLink',
|
|
13
|
-
defaultMessage: 'Open link',
|
|
14
|
-
description: 'Follows the hyperlink.',
|
|
15
|
-
},
|
|
16
|
-
unlink: {
|
|
17
|
-
id: 'fabric.editor.unlink',
|
|
18
|
-
defaultMessage: 'Unlink',
|
|
19
|
-
description: 'Removes the hyperlink but keeps your text.',
|
|
20
|
-
},
|
|
21
|
-
});
|
|
22
|
-
var HyperlinkEdit = /** @class */ (function (_super) {
|
|
23
|
-
tslib_1.__extends(HyperlinkEdit, _super);
|
|
24
|
-
function HyperlinkEdit(props) {
|
|
25
|
-
var _this = _super.call(this, props) || this;
|
|
26
|
-
_this.handleChange = function (text) {
|
|
27
|
-
_this.setState({ text: text });
|
|
28
|
-
};
|
|
29
|
-
_this.handleBlur = function () {
|
|
30
|
-
if (_this.props.onBlur) {
|
|
31
|
-
_this.props.onBlur(_this.state.text);
|
|
32
|
-
}
|
|
33
|
-
};
|
|
34
|
-
_this.handleSubmit = function () {
|
|
35
|
-
if (_this.props.onSubmit) {
|
|
36
|
-
_this.props.onSubmit(_this.state.text);
|
|
37
|
-
}
|
|
38
|
-
};
|
|
39
|
-
_this.state = { text: props.defaultValue || '' };
|
|
40
|
-
return _this;
|
|
41
|
-
}
|
|
42
|
-
HyperlinkEdit.prototype.render = function () {
|
|
43
|
-
var _a = this.props, target = _a.target, popupsMountPoint = _a.popupsMountPoint, popupsBoundariesElement = _a.popupsBoundariesElement, placeholder = _a.placeholder, onUnlink = _a.onUnlink, autoFocus = _a.autoFocus, onOpenLink = _a.onOpenLink, defaultValue = _a.defaultValue, alwaysOpenLinkAt = _a.alwaysOpenLinkAt, formatMessage = _a.intl.formatMessage;
|
|
44
|
-
var labelOpenLink = formatMessage(messages.openLink);
|
|
45
|
-
var labelUnlink = formatMessage(messages.unlink);
|
|
46
|
-
return (React.createElement(FloatingToolbar, { target: getNearestNonTextNode(target), popupsMountPoint: popupsMountPoint, popupsBoundariesElement: popupsBoundariesElement, fitWidth: 400, fitHeight: 32, offset: [0, 12], className: "normal", zIndex: akEditorFloatingDialogZIndex },
|
|
47
|
-
React.createElement(PanelTextInput, { autoFocus: autoFocus, defaultValue: defaultValue || '', placeholder: placeholder, onSubmit: this.handleSubmit, onChange: this.handleChange, onBlur: this.handleBlur, onCancel: this.handleBlur }),
|
|
48
|
-
(onOpenLink || onUnlink) && React.createElement(Separator, null),
|
|
49
|
-
onOpenLink && (React.createElement(ToolbarButton, { spacing: "compact", href: alwaysOpenLinkAt || this.state.text, onClick: onOpenLink, target: "_blank", title: labelOpenLink, iconBefore: React.createElement(OpenIcon, { label: labelOpenLink }) })),
|
|
50
|
-
onUnlink && (React.createElement(ToolbarButton, { spacing: "compact", onClick: onUnlink, title: labelUnlink, iconBefore: React.createElement(UnlinkIcon, { label: labelUnlink }) }))));
|
|
51
|
-
};
|
|
52
|
-
return HyperlinkEdit;
|
|
53
|
-
}(React.Component));
|
|
54
|
-
export default injectIntl(HyperlinkEdit);
|
|
55
|
-
//# sourceMappingURL=index.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../../src/plugins/hyperlink/ui/HyperlinkEdit/index.tsx"],"names":[],"mappings":";AAAA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAC/B,OAAO,EAAE,cAAc,EAAE,UAAU,EAAqB,MAAM,YAAY,CAAC;AAE3E,OAAO,QAAQ,MAAM,kCAAkC,CAAC;AACxD,OAAO,UAAU,MAAM,oCAAoC,CAAC;AAC5D,OAAO,EAAE,4BAA4B,EAAE,MAAM,yBAAyB,CAAC;AACvE,OAAO,cAAc,MAAM,+BAA+B,CAAC;AAC3D,OAAO,EAAE,qBAAqB,EAAE,MAAM,gCAAgC,CAAC;AACvE,OAAO,EAAE,eAAe,EAAE,SAAS,EAAE,aAAa,EAAE,MAAM,WAAW,CAAC;AAEtE,MAAM,CAAC,IAAM,QAAQ,GAAG,cAAc,CAAC;IACrC,QAAQ,EAAE;QACR,EAAE,EAAE,wBAAwB;QAC5B,cAAc,EAAE,WAAW;QAC3B,WAAW,EAAE,wBAAwB;KACtC;IACD,MAAM,EAAE;QACN,EAAE,EAAE,sBAAsB;QAC1B,cAAc,EAAE,QAAQ;QACxB,WAAW,EAAE,4CAA4C;KAC1D;CACF,CAAC,CAAC;AAwBH;IAA4B,yCAAiD;IAC3E,uBAAY,KAAK;QAAjB,YACE,kBAAM,KAAK,CAAC,SAEb;QAED,kBAAY,GAAG,UAAC,IAAY;YAC1B,KAAI,CAAC,QAAQ,CAAC,EAAE,IAAI,MAAA,EAAE,CAAC,CAAC;QAC1B,CAAC,CAAC;QAEF,gBAAU,GAAG;YACX,IAAI,KAAI,CAAC,KAAK,CAAC,MAAM,EAAE;gBACrB,KAAI,CAAC,KAAK,CAAC,MAAM,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