@atlaskit/share 4.2.0 → 4.2.2
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 +12 -0
- package/clients/package.json +2 -2
- package/copy-link-button/package.json +2 -2
- package/dist/cjs/components/analytics/analytics.js +1 -1
- package/dist/cjs/i18n/cs.js +37 -37
- package/dist/cjs/i18n/da.js +37 -37
- package/dist/cjs/i18n/de.js +37 -37
- package/dist/cjs/i18n/en.js +37 -37
- package/dist/cjs/i18n/en_GB.js +37 -37
- package/dist/cjs/i18n/es.js +37 -37
- package/dist/cjs/i18n/fi.js +37 -37
- package/dist/cjs/i18n/fr.js +37 -37
- package/dist/cjs/i18n/hu.js +37 -37
- package/dist/cjs/i18n/it.js +37 -37
- package/dist/cjs/i18n/ja.js +37 -37
- package/dist/cjs/i18n/ko.js +37 -37
- package/dist/cjs/i18n/nb.js +37 -37
- package/dist/cjs/i18n/nl.js +37 -37
- package/dist/cjs/i18n/pl.js +37 -37
- package/dist/cjs/i18n/pt_BR.js +37 -37
- package/dist/cjs/i18n/ru.js +37 -37
- package/dist/cjs/i18n/sv.js +37 -37
- package/dist/cjs/i18n/th.js +37 -37
- package/dist/cjs/i18n/tr.js +37 -37
- package/dist/cjs/i18n/uk.js +37 -37
- package/dist/cjs/i18n/vi.js +37 -37
- package/dist/cjs/i18n/zh.js +37 -37
- package/dist/cjs/i18n/zh_TW.js +37 -37
- package/dist/cjs/version.json +1 -1
- package/dist/es2019/components/analytics/analytics.js +1 -1
- package/dist/es2019/i18n/cs.js +37 -37
- package/dist/es2019/i18n/da.js +37 -37
- package/dist/es2019/i18n/de.js +37 -37
- package/dist/es2019/i18n/en.js +37 -37
- package/dist/es2019/i18n/en_GB.js +37 -37
- package/dist/es2019/i18n/es.js +37 -37
- package/dist/es2019/i18n/fi.js +37 -37
- package/dist/es2019/i18n/fr.js +37 -37
- package/dist/es2019/i18n/hu.js +37 -37
- package/dist/es2019/i18n/it.js +37 -37
- package/dist/es2019/i18n/ja.js +37 -37
- package/dist/es2019/i18n/ko.js +37 -37
- package/dist/es2019/i18n/nb.js +37 -37
- package/dist/es2019/i18n/nl.js +37 -37
- package/dist/es2019/i18n/pl.js +37 -37
- package/dist/es2019/i18n/pt_BR.js +37 -37
- package/dist/es2019/i18n/ru.js +37 -37
- package/dist/es2019/i18n/sv.js +37 -37
- package/dist/es2019/i18n/th.js +37 -37
- package/dist/es2019/i18n/tr.js +37 -37
- package/dist/es2019/i18n/uk.js +37 -37
- package/dist/es2019/i18n/vi.js +37 -37
- package/dist/es2019/i18n/zh.js +37 -37
- package/dist/es2019/i18n/zh_TW.js +37 -37
- package/dist/es2019/version.json +1 -1
- package/dist/esm/components/analytics/analytics.js +1 -1
- package/dist/esm/i18n/cs.js +37 -37
- package/dist/esm/i18n/da.js +37 -37
- package/dist/esm/i18n/de.js +37 -37
- package/dist/esm/i18n/en.js +37 -37
- package/dist/esm/i18n/en_GB.js +37 -37
- package/dist/esm/i18n/es.js +37 -37
- package/dist/esm/i18n/fi.js +37 -37
- package/dist/esm/i18n/fr.js +37 -37
- package/dist/esm/i18n/hu.js +37 -37
- package/dist/esm/i18n/it.js +37 -37
- package/dist/esm/i18n/ja.js +37 -37
- package/dist/esm/i18n/ko.js +37 -37
- package/dist/esm/i18n/nb.js +37 -37
- package/dist/esm/i18n/nl.js +37 -37
- package/dist/esm/i18n/pl.js +37 -37
- package/dist/esm/i18n/pt_BR.js +37 -37
- package/dist/esm/i18n/ru.js +37 -37
- package/dist/esm/i18n/sv.js +37 -37
- package/dist/esm/i18n/th.js +37 -37
- package/dist/esm/i18n/tr.js +37 -37
- package/dist/esm/i18n/uk.js +37 -37
- package/dist/esm/i18n/vi.js +37 -37
- package/dist/esm/i18n/zh.js +37 -37
- package/dist/esm/i18n/zh_TW.js +37 -37
- package/dist/esm/version.json +1 -1
- package/dist/types/clients/ShareServiceClient.d.ts +3 -3
- package/dist/types/components/CommentField.d.ts +1 -1
- package/dist/types/components/CopyLinkButton.d.ts +3 -3
- package/dist/types/components/IntegrationButton.d.ts +1 -1
- package/dist/types/components/IntegrationForm.d.ts +1 -1
- package/dist/types/components/LazyShareForm/LazyShareForm.d.ts +1 -1
- package/dist/types/components/ShareButton.d.ts +1 -1
- package/dist/types/components/ShareDialogContainer.d.ts +1 -1
- package/dist/types/components/ShareDialogWithTrigger.d.ts +1 -1
- package/dist/types/components/ShareForm.d.ts +2 -2
- package/dist/types/components/ShareFormWrapper/ShareFormWrapper.d.ts +1 -1
- package/dist/types/components/ShareHeader.d.ts +1 -1
- package/dist/types/components/SplitButton.d.ts +1 -1
- package/dist/types/components/UserPickerField.d.ts +1 -1
- package/dist/types/components/analytics/analytics.d.ts +4 -4
- package/dist/types/components/utils.d.ts +3 -4
- package/dist/types/i18n/cs.d.ts +39 -39
- package/dist/types/i18n/da.d.ts +39 -39
- package/dist/types/i18n/de.d.ts +39 -39
- package/dist/types/i18n/en.d.ts +39 -39
- package/dist/types/i18n/en_GB.d.ts +39 -39
- package/dist/types/i18n/en_ZZ.d.ts +6 -6
- package/dist/types/i18n/es.d.ts +39 -39
- package/dist/types/i18n/et.d.ts +6 -6
- package/dist/types/i18n/fi.d.ts +39 -39
- package/dist/types/i18n/fr.d.ts +39 -39
- package/dist/types/i18n/hu.d.ts +39 -39
- package/dist/types/i18n/is.d.ts +6 -6
- package/dist/types/i18n/it.d.ts +39 -39
- package/dist/types/i18n/ja.d.ts +39 -39
- package/dist/types/i18n/ko.d.ts +39 -39
- package/dist/types/i18n/languages.d.ts +6 -6
- package/dist/types/i18n/nb.d.ts +39 -39
- package/dist/types/i18n/nl.d.ts +39 -39
- package/dist/types/i18n/pl.d.ts +39 -39
- package/dist/types/i18n/pt_BR.d.ts +39 -39
- package/dist/types/i18n/pt_PT.d.ts +6 -6
- package/dist/types/i18n/ro.d.ts +6 -6
- package/dist/types/i18n/ru.d.ts +39 -39
- package/dist/types/i18n/sk.d.ts +6 -6
- package/dist/types/i18n/sv.d.ts +39 -39
- package/dist/types/i18n/th.d.ts +39 -39
- package/dist/types/i18n/tr.d.ts +39 -39
- package/dist/types/i18n/uk.d.ts +39 -39
- package/dist/types/i18n/vi.d.ts +39 -39
- package/dist/types/i18n/zh.d.ts +39 -39
- package/dist/types/i18n/zh_TW.d.ts +39 -39
- package/dist/types/types/Flag.d.ts +3 -3
- package/dist/types/types/OriginTracing.d.ts +5 -5
- package/dist/types/types/Products.d.ts +2 -2
- package/dist/types/types/ShareButton.d.ts +2 -2
- package/dist/types/types/ShareContentState.d.ts +3 -3
- package/dist/types/types/ShareDialogContainer.d.ts +1 -1
- package/dist/types/types/ShareDialogWithTrigger.d.ts +5 -5
- package/dist/types/types/ShareEntities.d.ts +6 -6
- package/dist/types/types/ShareForm.d.ts +1 -1
- package/dist/types/types/User.d.ts +3 -3
- package/dist/types/types/form.d.ts +1 -1
- package/dist/types/types/index.d.ts +1 -1
- package/dist/types/util/i18n-util.d.ts +2 -2
- package/dist/types-ts4.5/clients/AtlassianUrlShortenerClient.d.ts +16 -0
- package/dist/types-ts4.5/clients/ShareServiceClient.d.ts +25 -0
- package/dist/types-ts4.5/clients/index.d.ts +2 -0
- package/dist/types-ts4.5/components/CommentField.d.ts +6 -0
- package/dist/types-ts4.5/components/CopyLinkButton.d.ts +37 -0
- package/dist/types-ts4.5/components/ErrorBoundary.d.ts +4 -0
- package/dist/types-ts4.5/components/IntegrationButton.d.ts +10 -0
- package/dist/types-ts4.5/components/IntegrationForm.d.ts +11 -0
- package/dist/types-ts4.5/components/LazyShareForm/LazyShareForm.d.ts +20 -0
- package/dist/types-ts4.5/components/LazyShareForm/index.d.ts +1 -0
- package/dist/types-ts4.5/components/LazyShareForm/lazy.d.ts +4 -0
- package/dist/types-ts4.5/components/MessagesIntlProvider.d.ts +9 -0
- package/dist/types-ts4.5/components/ShareButton.d.ts +13 -0
- package/dist/types-ts4.5/components/ShareDialogContainer.d.ts +57 -0
- package/dist/types-ts4.5/components/ShareDialogWithTrigger.d.ts +43 -0
- package/dist/types-ts4.5/components/ShareForm.d.ts +11 -0
- package/dist/types-ts4.5/components/ShareFormWrapper/ShareFormWrapper.d.ts +9 -0
- package/dist/types-ts4.5/components/ShareFormWrapper/index.d.ts +1 -0
- package/dist/types-ts4.5/components/ShareFormWrapper/styled.d.ts +10 -0
- package/dist/types-ts4.5/components/ShareHeader.d.ts +8 -0
- package/dist/types-ts4.5/components/SlackIcon.d.ts +3 -0
- package/dist/types-ts4.5/components/SplitButton.d.ts +19 -0
- package/dist/types-ts4.5/components/UserPickerField.d.ts +29 -0
- package/dist/types-ts4.5/components/analytics/analytics.d.ts +19 -0
- package/dist/types-ts4.5/components/analytics/ufoExperienceHelper.d.ts +2 -0
- package/dist/types-ts4.5/components/analytics/ufoExperiences.d.ts +3 -0
- package/dist/types-ts4.5/components/colorSlackIcon.d.ts +3 -0
- package/dist/types-ts4.5/components/localStorageUtils.d.ts +5 -0
- package/dist/types-ts4.5/components/monochromeSlackIcon.d.ts +3 -0
- package/dist/types-ts4.5/components/styles.d.ts +5 -0
- package/dist/types-ts4.5/components/utils.d.ts +19 -0
- package/dist/types-ts4.5/i18n/cs.d.ts +46 -0
- package/dist/types-ts4.5/i18n/da.d.ts +46 -0
- package/dist/types-ts4.5/i18n/de.d.ts +46 -0
- package/dist/types-ts4.5/i18n/en.d.ts +46 -0
- package/dist/types-ts4.5/i18n/en_GB.d.ts +46 -0
- package/dist/types-ts4.5/i18n/en_ZZ.d.ts +43 -0
- package/dist/types-ts4.5/i18n/es.d.ts +46 -0
- package/dist/types-ts4.5/i18n/et.d.ts +30 -0
- package/dist/types-ts4.5/i18n/fi.d.ts +46 -0
- package/dist/types-ts4.5/i18n/fr.d.ts +46 -0
- package/dist/types-ts4.5/i18n/hu.d.ts +46 -0
- package/dist/types-ts4.5/i18n/index.d.ts +36 -0
- package/dist/types-ts4.5/i18n/is.d.ts +33 -0
- package/dist/types-ts4.5/i18n/it.d.ts +46 -0
- package/dist/types-ts4.5/i18n/ja.d.ts +46 -0
- package/dist/types-ts4.5/i18n/ko.d.ts +46 -0
- package/dist/types-ts4.5/i18n/languages.d.ts +33 -0
- package/dist/types-ts4.5/i18n/nb.d.ts +46 -0
- package/dist/types-ts4.5/i18n/nl.d.ts +46 -0
- package/dist/types-ts4.5/i18n/pl.d.ts +46 -0
- package/dist/types-ts4.5/i18n/pt_BR.d.ts +46 -0
- package/dist/types-ts4.5/i18n/pt_PT.d.ts +30 -0
- package/dist/types-ts4.5/i18n/ro.d.ts +33 -0
- package/dist/types-ts4.5/i18n/ru.d.ts +46 -0
- package/dist/types-ts4.5/i18n/sk.d.ts +30 -0
- package/dist/types-ts4.5/i18n/sv.d.ts +46 -0
- package/dist/types-ts4.5/i18n/th.d.ts +46 -0
- package/dist/types-ts4.5/i18n/tr.d.ts +46 -0
- package/dist/types-ts4.5/i18n/uk.d.ts +46 -0
- package/dist/types-ts4.5/i18n/vi.d.ts +46 -0
- package/dist/types-ts4.5/i18n/zh.d.ts +46 -0
- package/dist/types-ts4.5/i18n/zh_TW.d.ts +46 -0
- package/dist/types-ts4.5/i18n.d.ts +187 -0
- package/dist/types-ts4.5/index.d.ts +4 -0
- package/dist/types-ts4.5/types/Flag.d.ts +13 -0
- package/dist/types-ts4.5/types/OriginTracing.d.ts +17 -0
- package/dist/types-ts4.5/types/Products.d.ts +3 -0
- package/dist/types-ts4.5/types/ShareButton.d.ts +2 -0
- package/dist/types-ts4.5/types/ShareContentState.d.ts +14 -0
- package/dist/types-ts4.5/types/ShareDialogContainer.d.ts +147 -0
- package/dist/types-ts4.5/types/ShareDialogWithTrigger.d.ts +45 -0
- package/dist/types-ts4.5/types/ShareEntities.d.ts +30 -0
- package/dist/types-ts4.5/types/ShareForm.d.ts +31 -0
- package/dist/types-ts4.5/types/User.d.ts +9 -0
- package/dist/types-ts4.5/types/form.d.ts +5 -0
- package/dist/types-ts4.5/types/index.d.ts +17 -0
- package/dist/types-ts4.5/util/i18n-util.d.ts +17 -0
- package/package.json +13 -5
- package/tmp/api-report-tmp.d.ts +319 -0
|
@@ -1,46 +1,46 @@
|
|
|
1
|
-
declare const _default: {
|
|
2
|
-
"fabric.elements.share.copied.to.clipboard.message": string;
|
|
3
|
-
"fabric.elements.share.copylink.button.text": string;
|
|
4
|
-
"fabric.elements.share.copypubliclink.button.text": string;
|
|
5
|
-
"fabric.elements.share.failure.icon.label": string;
|
|
6
|
-
"fabric.elements.share.failure.message": string;
|
|
7
|
-
"fabric.elements.share.form.comment.placeholder": string;
|
|
8
|
-
"fabric.elements.share.form.info.message.no.invite.confluence": string;
|
|
9
|
-
"fabric.elements.share.form.info.message.no.invite.jira": string;
|
|
10
|
-
"fabric.elements.share.form.no-permissions": string;
|
|
11
|
-
"fabric.elements.share.form.public.send": string;
|
|
12
|
-
"fabric.elements.share.form.public.share": string;
|
|
13
|
-
"fabric.elements.share.form.retry": string;
|
|
14
|
-
"fabric.elements.share.form.send": string;
|
|
15
|
-
"fabric.elements.share.form.share": string;
|
|
16
|
-
"fabric.elements.share.form.title": string;
|
|
17
|
-
"fabric.elements.share.form.user-picker.add-more": string;
|
|
18
|
-
"fabric.elements.share.form.user-picker.no-options.existingUserOnly": string;
|
|
19
|
-
"fabric.elements.share.form.user-picker.no-options.generic": string;
|
|
20
|
-
"fabric.elements.share.form.user-picker.placeholder.emailOnly": string;
|
|
21
|
-
"fabric.elements.share.form.user-picker.placeholder.existingUserOnly": string;
|
|
22
|
-
"fabric.elements.share.form.user-picker.placeholder.generic": string;
|
|
23
|
-
"fabric.elements.share.form.user-picker.placeholder.jira": string;
|
|
24
|
-
"fabric.elements.share.form.user-picker.placholder.generic.existingUserOnly": string;
|
|
25
|
-
"fabric.elements.share.form.user-picker.validation.required": string;
|
|
26
|
-
"fabric.elements.share.form.user-picker.validation.required.email-only": string;
|
|
27
|
-
"fabric.elements.share.form.user-picker.validation.required.existingUserOnly": string;
|
|
28
|
-
"fabric.elements.share.form.user-picker.validation.required.jira": string;
|
|
29
|
-
"fabric.elements.share.form.user-picker.validation.required.jira.existingUserOnly": string;
|
|
30
|
-
"fabric.elements.share.in.integration.button": string;
|
|
31
|
-
"fabric.elements.share.main.tab.text.confluence": string;
|
|
32
|
-
"fabric.elements.share.main.tab.text.jira": string;
|
|
33
|
-
"fabric.elements.share.success.message": string;
|
|
34
|
-
"fabric.elements.share.to.integration.button": string;
|
|
35
|
-
"fabric.elements.share.trigger.button.icon.label": string;
|
|
36
|
-
"fabric.elements.share.trigger.button.invite.text": string;
|
|
37
|
-
"fabric.elements.share.trigger.button.text": string;
|
|
38
|
-
"fabric.elements.share.trigger.button.tooltip.text": string;
|
|
39
|
-
};
|
|
40
1
|
/**
|
|
41
2
|
* NOTE:
|
|
42
3
|
*
|
|
43
4
|
* This file is automatically generated by Traduki 2.0.
|
|
44
5
|
* DO NOT CHANGE IT BY HAND or your changes will be lost.
|
|
45
6
|
*/
|
|
7
|
+
declare const _default: {
|
|
8
|
+
'fabric.elements.share.copied.to.clipboard.message': string;
|
|
9
|
+
'fabric.elements.share.copylink.button.text': string;
|
|
10
|
+
'fabric.elements.share.copypubliclink.button.text': string;
|
|
11
|
+
'fabric.elements.share.failure.icon.label': string;
|
|
12
|
+
'fabric.elements.share.failure.message': string;
|
|
13
|
+
'fabric.elements.share.form.comment.placeholder': string;
|
|
14
|
+
'fabric.elements.share.form.info.message.no.invite.confluence': string;
|
|
15
|
+
'fabric.elements.share.form.info.message.no.invite.jira': string;
|
|
16
|
+
'fabric.elements.share.form.no-permissions': string;
|
|
17
|
+
'fabric.elements.share.form.public.send': string;
|
|
18
|
+
'fabric.elements.share.form.public.share': string;
|
|
19
|
+
'fabric.elements.share.form.retry': string;
|
|
20
|
+
'fabric.elements.share.form.send': string;
|
|
21
|
+
'fabric.elements.share.form.share': string;
|
|
22
|
+
'fabric.elements.share.form.title': string;
|
|
23
|
+
'fabric.elements.share.form.user-picker.add-more': string;
|
|
24
|
+
'fabric.elements.share.form.user-picker.no-options.existingUserOnly': string;
|
|
25
|
+
'fabric.elements.share.form.user-picker.no-options.generic': string;
|
|
26
|
+
'fabric.elements.share.form.user-picker.placeholder.emailOnly': string;
|
|
27
|
+
'fabric.elements.share.form.user-picker.placeholder.existingUserOnly': string;
|
|
28
|
+
'fabric.elements.share.form.user-picker.placeholder.generic': string;
|
|
29
|
+
'fabric.elements.share.form.user-picker.placeholder.jira': string;
|
|
30
|
+
'fabric.elements.share.form.user-picker.placholder.generic.existingUserOnly': string;
|
|
31
|
+
'fabric.elements.share.form.user-picker.validation.required': string;
|
|
32
|
+
'fabric.elements.share.form.user-picker.validation.required.email-only': string;
|
|
33
|
+
'fabric.elements.share.form.user-picker.validation.required.existingUserOnly': string;
|
|
34
|
+
'fabric.elements.share.form.user-picker.validation.required.jira': string;
|
|
35
|
+
'fabric.elements.share.form.user-picker.validation.required.jira.existingUserOnly': string;
|
|
36
|
+
'fabric.elements.share.in.integration.button': string;
|
|
37
|
+
'fabric.elements.share.main.tab.text.confluence': string;
|
|
38
|
+
'fabric.elements.share.main.tab.text.jira': string;
|
|
39
|
+
'fabric.elements.share.success.message': string;
|
|
40
|
+
'fabric.elements.share.to.integration.button': string;
|
|
41
|
+
'fabric.elements.share.trigger.button.icon.label': string;
|
|
42
|
+
'fabric.elements.share.trigger.button.invite.text': string;
|
|
43
|
+
'fabric.elements.share.trigger.button.text': string;
|
|
44
|
+
'fabric.elements.share.trigger.button.tooltip.text': string;
|
|
45
|
+
};
|
|
46
46
|
export default _default;
|
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
export declare const OBJECT_SHARED = "object-shared";
|
|
2
2
|
export declare const ADMIN_NOTIFIED = "admin-notified";
|
|
3
|
-
export
|
|
4
|
-
export
|
|
3
|
+
export type FlagType = 'object-shared' | 'admin-notified';
|
|
4
|
+
export type MessageDescriptor = {
|
|
5
5
|
id: string;
|
|
6
6
|
description: string;
|
|
7
7
|
defaultMessage: string;
|
|
8
8
|
};
|
|
9
|
-
export
|
|
9
|
+
export type Flag = {
|
|
10
10
|
appearance: 'success';
|
|
11
11
|
title: MessageDescriptor;
|
|
12
12
|
type: FlagType;
|
|
@@ -1,17 +1,17 @@
|
|
|
1
|
-
export
|
|
1
|
+
export type OriginTracingWithIdGenerated = {
|
|
2
2
|
originIdGenerated: string;
|
|
3
3
|
originProduct: string;
|
|
4
4
|
};
|
|
5
|
-
export
|
|
5
|
+
export type OriginTracingForSubSequentEvents = {
|
|
6
6
|
originId: string;
|
|
7
7
|
originProduct: string;
|
|
8
8
|
};
|
|
9
|
-
export
|
|
9
|
+
export type OriginAnalyticAttributes = {
|
|
10
10
|
hasGeneratedId: boolean;
|
|
11
11
|
};
|
|
12
|
-
export
|
|
12
|
+
export type OriginTracing = {
|
|
13
13
|
id: string;
|
|
14
14
|
addToUrl: (link: string) => string;
|
|
15
15
|
toAnalyticsAttributes: (attrs: OriginAnalyticAttributes) => OriginTracingWithIdGenerated | OriginTracingForSubSequentEvents;
|
|
16
16
|
};
|
|
17
|
-
export
|
|
17
|
+
export type OriginTracingFactory = () => OriginTracing;
|
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
/** Product ID (Canonical ID) in ARI of the share request */
|
|
2
|
-
export
|
|
3
|
-
export
|
|
2
|
+
export type ProductId = 'bitbucket' | 'confluence' | 'jira-addon' | 'jira-core' | 'jira-platform' | 'jira-polaris' | 'jira-portfolio' | 'jira-servicedesk' | 'jira-software' | 'jira-unknown' | 'trello';
|
|
3
|
+
export type ProductName = 'jira' | 'confluence';
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export
|
|
2
|
-
export
|
|
1
|
+
export type ShareButtonStyle = 'icon-only' | 'icon-with-text' | 'text-only';
|
|
2
|
+
export type TooltipPosition = 'top' | 'right' | 'bottom' | 'left' | 'mouse';
|
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
import { OptionData } from '@atlaskit/smart-user-picker';
|
|
2
2
|
import { Comment } from './ShareEntities';
|
|
3
3
|
import { User } from './User';
|
|
4
|
-
export
|
|
4
|
+
export type ShareContentState = {
|
|
5
5
|
users: User[];
|
|
6
6
|
comment?: Comment;
|
|
7
7
|
};
|
|
8
|
-
export
|
|
8
|
+
export type ShareError = {
|
|
9
9
|
message: string;
|
|
10
10
|
};
|
|
11
|
-
export
|
|
11
|
+
export type ShareData = {
|
|
12
12
|
users: OptionData[];
|
|
13
13
|
comment: Comment;
|
|
14
14
|
};
|
|
@@ -10,7 +10,7 @@ import type { ProductId, ProductName } from './Products';
|
|
|
10
10
|
import type { ShareButtonStyle, TooltipPosition } from './ShareButton';
|
|
11
11
|
import type { DialogPlacement, RenderCustomTriggerButton } from './ShareDialogWithTrigger';
|
|
12
12
|
import type { Integration, IntegrationMode } from './ShareEntities';
|
|
13
|
-
export
|
|
13
|
+
export type ShareDialogContainerProps = {
|
|
14
14
|
onTriggerButtonClick?: () => void;
|
|
15
15
|
onDialogOpen?: () => void;
|
|
16
16
|
onDialogClose?: () => void;
|
|
@@ -7,19 +7,19 @@ import type { OriginTracing } from './OriginTracing';
|
|
|
7
7
|
import type { ShareData, ShareError } from './ShareContentState';
|
|
8
8
|
import type { ShareDialogContainerProps } from './ShareDialogContainer';
|
|
9
9
|
import type { Integration } from './ShareEntities';
|
|
10
|
-
export
|
|
10
|
+
export type RenderCustomTriggerButton = (args: {
|
|
11
11
|
error?: ShareError;
|
|
12
12
|
isDisabled?: boolean;
|
|
13
13
|
isSelected?: boolean;
|
|
14
14
|
onClick: () => void;
|
|
15
15
|
}, triggerProps: TriggerProps) => React.ReactNode;
|
|
16
|
-
export
|
|
16
|
+
export type DialogPlacement = Placement;
|
|
17
17
|
/**
|
|
18
18
|
* Ideally, this would be Pick<PopupProps, ''>, but that doesn't play well
|
|
19
19
|
* with the demo page and clearly visible options on that page.
|
|
20
20
|
*/
|
|
21
|
-
export
|
|
22
|
-
export
|
|
21
|
+
export type DialogBoundariesElement = 'viewport' | 'window' | 'scrollParent';
|
|
22
|
+
export type ShareDialogWithTriggerProps = Pick<ShareDialogContainerProps, 'onTriggerButtonClick' | 'isAutoOpenDialog' | 'shouldCloseOnEscapePress' | 'dialogPlacement' | 'loadUserOptions' | 'onDialogOpen' | 'onDialogClose' | 'onUserSelectionChange' | 'renderCustomTriggerButton' | 'shareContentType' | 'shareFormTitle' | 'shareFormHelperMessage' | 'showFlags' | 'enableSmartUserPicker' | 'loggedInAccountId' | 'triggerButtonAppearance' | 'triggerButtonIcon' | 'triggerButtonStyle' | 'triggerButtonTooltipPosition' | 'triggerButtonTooltipText' | 'cloudId' | 'bottomMessage' | 'product' | 'customFooter' | 'isCopyDisabled' | 'isPublicLink' | 'integrationMode' | 'shareFieldsFooter' | 'shareIntegrations' | 'shareAri' | 'tabIndex' | 'copyTooltipText' | 'dialogZIndex' | 'orgId' | 'isBrowseUsersDisabled'> & {
|
|
23
23
|
config?: ConfigResponse;
|
|
24
24
|
isFetchingConfig?: boolean;
|
|
25
25
|
children?: RenderCustomTriggerButton;
|
|
@@ -31,7 +31,7 @@ export declare type ShareDialogWithTriggerProps = Pick<ShareDialogContainerProps
|
|
|
31
31
|
formShareOrigin?: OriginTracing;
|
|
32
32
|
submitButtonLabel?: React.ReactNode;
|
|
33
33
|
};
|
|
34
|
-
export
|
|
34
|
+
export type ShareDialogWithTriggerStates = {
|
|
35
35
|
isLoading: boolean;
|
|
36
36
|
isDialogOpen: boolean;
|
|
37
37
|
isSharing: boolean;
|
|
@@ -1,20 +1,20 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
|
-
export
|
|
2
|
+
export type Content = {
|
|
3
3
|
ari: string;
|
|
4
4
|
link: string;
|
|
5
5
|
title: string;
|
|
6
6
|
type: string;
|
|
7
7
|
};
|
|
8
|
-
export
|
|
8
|
+
export type Comment = {
|
|
9
9
|
format: 'plain_text' | 'adf';
|
|
10
10
|
value: string;
|
|
11
11
|
};
|
|
12
|
-
export
|
|
12
|
+
export type MetaData = {
|
|
13
13
|
productId: string;
|
|
14
14
|
atlOriginId: string;
|
|
15
15
|
shareeAction?: 'view' | 'edit';
|
|
16
16
|
};
|
|
17
|
-
export
|
|
17
|
+
export type IntegrationContentProps = {
|
|
18
18
|
onClose: () => void;
|
|
19
19
|
changeTab?: (index: TabType) => void;
|
|
20
20
|
};
|
|
@@ -22,9 +22,9 @@ export declare enum TabType {
|
|
|
22
22
|
default = 0,
|
|
23
23
|
Slack = 1
|
|
24
24
|
}
|
|
25
|
-
export
|
|
25
|
+
export type Integration = {
|
|
26
26
|
type: string;
|
|
27
27
|
Icon: React.ComponentType;
|
|
28
28
|
Content: React.ComponentType<IntegrationContentProps>;
|
|
29
29
|
};
|
|
30
|
-
export
|
|
30
|
+
export type IntegrationMode = 'tabs' | 'split' | 'off';
|
|
@@ -4,7 +4,7 @@ import type { ConfigResponse } from '../clients/ShareServiceClient';
|
|
|
4
4
|
import type { ProductName } from './Products';
|
|
5
5
|
import type { ShareData, ShareError } from './ShareContentState';
|
|
6
6
|
import type { ShareDialogContainerProps } from './ShareDialogContainer';
|
|
7
|
-
export
|
|
7
|
+
export type ShareFormProps = Pick<ShareDialogContainerProps, 'integrationMode' | 'shareIntegrations' | 'copyTooltipText' | 'isPublicLink' | 'onUserSelectionChange' | 'cloudId' | 'loggedInAccountId' | 'enableSmartUserPicker' | 'orgId' | 'isBrowseUsersDisabled'> & {
|
|
8
8
|
config?: ConfigResponse;
|
|
9
9
|
isFetchingConfig?: boolean;
|
|
10
10
|
copyLink: string;
|
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
export
|
|
1
|
+
export type UserWithId = {
|
|
2
2
|
type: 'user' | 'group' | 'team' | 'custom';
|
|
3
3
|
id: string;
|
|
4
4
|
};
|
|
5
|
-
export
|
|
5
|
+
export type UserWithEmail = {
|
|
6
6
|
type: 'user';
|
|
7
7
|
email: string;
|
|
8
8
|
};
|
|
9
|
-
export
|
|
9
|
+
export type User = UserWithId | UserWithEmail;
|
|
@@ -10,7 +10,7 @@ export type { DialogPlacement, DialogBoundariesElement, RenderCustomTriggerButto
|
|
|
10
10
|
export type { User, UserWithEmail, UserWithId } from './User';
|
|
11
11
|
export type { Comment, Content, MetaData, Integration, IntegrationContentProps, } from './ShareEntities';
|
|
12
12
|
export { TabType } from './ShareEntities';
|
|
13
|
-
export
|
|
13
|
+
export type KeysOfType<T, TProp> = {
|
|
14
14
|
[P in keyof T]: T[P] extends TProp ? P : never;
|
|
15
15
|
}[keyof T];
|
|
16
16
|
export type { ShareDialogContainerProps } from './ShareDialogContainer';
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import languages from '../i18n/languages';
|
|
2
|
-
export
|
|
3
|
-
|
|
2
|
+
export type LangCode = keyof typeof languages | 'pt-BR' | 'pt-PT';
|
|
3
|
+
type LocaleMessages = {
|
|
4
4
|
[key: string]: string;
|
|
5
5
|
};
|
|
6
6
|
/**
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
export interface ShortenRequest {
|
|
2
|
+
cloudId?: string;
|
|
3
|
+
product: string;
|
|
4
|
+
type: string;
|
|
5
|
+
params: Record<string, string>;
|
|
6
|
+
originId?: string;
|
|
7
|
+
}
|
|
8
|
+
export interface ShortenResponse {
|
|
9
|
+
shortUrl: string;
|
|
10
|
+
}
|
|
11
|
+
export interface UrlShortenerClient {
|
|
12
|
+
shorten(data: ShortenRequest): Promise<ShortenResponse>;
|
|
13
|
+
}
|
|
14
|
+
export declare class AtlassianUrlShortenerClient implements UrlShortenerClient {
|
|
15
|
+
shorten(data: ShortenRequest): Promise<ShortenResponse>;
|
|
16
|
+
}
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
import { ServiceConfig } from '@atlaskit/util-service-support';
|
|
2
|
+
import { Comment, Content, MetaData, User } from '../types';
|
|
3
|
+
export interface ShareClient {
|
|
4
|
+
share(content: Content, recipients: User[], metadata: MetaData, comment?: Comment): Promise<ShareResponse>;
|
|
5
|
+
getConfig(cloudId: string): Promise<ConfigResponse>;
|
|
6
|
+
}
|
|
7
|
+
export type ShareRequest = (content: Content, recipients: User[], metadata: MetaData, comment?: Comment) => Promise<ShareResponse>;
|
|
8
|
+
export type ShareResponse = {
|
|
9
|
+
shareRequestId: string;
|
|
10
|
+
};
|
|
11
|
+
export type ConfigResponse = {
|
|
12
|
+
disableSharingToEmails?: boolean;
|
|
13
|
+
};
|
|
14
|
+
export declare const DEFAULT_SHARE_PATH = "share";
|
|
15
|
+
export declare const SHARE_CONFIG_PATH = "share/configuration";
|
|
16
|
+
export declare const DEFAULT_SHARE_SERVICE_URL = "/gateway/api";
|
|
17
|
+
export declare class ShareServiceClient implements ShareClient {
|
|
18
|
+
private serviceConfig;
|
|
19
|
+
constructor(serviceConfig?: Partial<ServiceConfig>);
|
|
20
|
+
getConfig(cloudId: string): Promise<ConfigResponse>;
|
|
21
|
+
/**
|
|
22
|
+
* To send a POST request to the share endpoint in Share service
|
|
23
|
+
*/
|
|
24
|
+
share(content: Content, recipients: User[], metadata: MetaData, comment?: Comment): Promise<ShareResponse>;
|
|
25
|
+
}
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
/** @jsx jsx */
|
|
2
|
+
import React, { ReactElement } from 'react';
|
|
3
|
+
import { jsx } from '@emotion/react';
|
|
4
|
+
import { TriggerProps } from '@atlaskit/popup';
|
|
5
|
+
export declare const AUTO_DISMISS_MS: number;
|
|
6
|
+
export declare const messageContainerStyle: import("@emotion/react").SerializedStyles;
|
|
7
|
+
type InputProps = {
|
|
8
|
+
text: string;
|
|
9
|
+
};
|
|
10
|
+
export declare const HiddenInput: React.ForwardRefExoticComponent<InputProps & React.RefAttributes<HTMLInputElement>>;
|
|
11
|
+
export type Props = {
|
|
12
|
+
onLinkCopy?: (link: string) => void;
|
|
13
|
+
link: string;
|
|
14
|
+
isDisabled?: boolean;
|
|
15
|
+
copyTooltipText?: string;
|
|
16
|
+
children?: string | ReactElement;
|
|
17
|
+
copyLinkButtonText: string;
|
|
18
|
+
copiedToClipboardText: string;
|
|
19
|
+
iconBefore?: ReactElement;
|
|
20
|
+
};
|
|
21
|
+
export type State = {
|
|
22
|
+
shouldShowCopiedMessage: boolean;
|
|
23
|
+
};
|
|
24
|
+
export declare class CopyLinkButton extends React.Component<Props, State> {
|
|
25
|
+
private autoDismiss;
|
|
26
|
+
private inputRef;
|
|
27
|
+
state: {
|
|
28
|
+
shouldShowCopiedMessage: boolean;
|
|
29
|
+
};
|
|
30
|
+
componentWillUnmount(): void;
|
|
31
|
+
private clearAutoDismiss;
|
|
32
|
+
private handleClick;
|
|
33
|
+
private handleDismissCopiedMessage;
|
|
34
|
+
renderTriggerButton: (triggerProps: TriggerProps) => jsx.JSX.Element;
|
|
35
|
+
render(): jsx.JSX.Element;
|
|
36
|
+
}
|
|
37
|
+
export default CopyLinkButton;
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import { WithAnalyticsEventsProps } from '@atlaskit/analytics-next';
|
|
3
|
+
declare const _default: React.ForwardRefExoticComponent<Omit<WithAnalyticsEventsProps, keyof WithAnalyticsEventsProps> & React.RefAttributes<any>>;
|
|
4
|
+
export default _default;
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
/** @jsx jsx */
|
|
2
|
+
import React from 'react';
|
|
3
|
+
import { CustomThemeButtonProps } from '@atlaskit/button/types';
|
|
4
|
+
type Props = CustomThemeButtonProps & {
|
|
5
|
+
text: React.ReactNode;
|
|
6
|
+
IntegrationIcon: React.ComponentType;
|
|
7
|
+
textColor?: string;
|
|
8
|
+
};
|
|
9
|
+
declare const IntegrationButton: React.FC<Props>;
|
|
10
|
+
export default IntegrationButton;
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
/** @jsx jsx */
|
|
2
|
+
import React from 'react';
|
|
3
|
+
import { jsx } from '@emotion/react';
|
|
4
|
+
import { IntegrationContentProps } from '../types';
|
|
5
|
+
export declare const formWrapperStyle: import("@emotion/react").SerializedStyles;
|
|
6
|
+
export type IntegrationFormProps = {
|
|
7
|
+
Content: React.ComponentType<IntegrationContentProps> | null;
|
|
8
|
+
onIntegrationClose?: () => void;
|
|
9
|
+
changeTab?: (index: number) => void;
|
|
10
|
+
};
|
|
11
|
+
export declare const IntegrationForm: ({ Content, onIntegrationClose, changeTab, }: IntegrationFormProps) => jsx.JSX.Element;
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import { jsx } from '@emotion/react';
|
|
2
|
+
import type { LoadOptions } from '@atlaskit/smart-user-picker';
|
|
3
|
+
import type { ShareData, ShareDialogWithTriggerProps, ShareDialogWithTriggerStates } from '../../types';
|
|
4
|
+
import { IntegrationFormProps } from '../IntegrationForm';
|
|
5
|
+
export type LazyShareFormProps = Pick<ShareDialogWithTriggerProps, 'copyLink' | 'config' | 'isFetchingConfig' | 'loadUserOptions' | 'shareFormTitle' | 'shareFormHelperMessage' | 'bottomMessage' | 'submitButtonLabel' | 'product' | 'customFooter' | 'enableSmartUserPicker' | 'loggedInAccountId' | 'cloudId' | 'shareFieldsFooter' | 'onUserSelectionChange' | 'isPublicLink' | 'copyTooltipText' | 'shareIntegrations' | 'integrationMode' | 'onDialogClose' | 'orgId' | 'isBrowseUsersDisabled'> & Pick<ShareDialogWithTriggerStates, 'showIntegrationForm' | 'selectedIntegration' | 'isSharing' | 'shareError' | 'defaultValue'> & Pick<IntegrationFormProps, 'Content'> & {
|
|
6
|
+
onLinkCopy: () => void;
|
|
7
|
+
onDismiss: (data: ShareData) => void;
|
|
8
|
+
onSubmit: (data: ShareData) => void;
|
|
9
|
+
onTabChange: (index: number) => void;
|
|
10
|
+
loadOptions?: LoadOptions;
|
|
11
|
+
selectPortalRef: any;
|
|
12
|
+
showTitle: boolean;
|
|
13
|
+
setIsLoading: (isLoading: boolean) => void;
|
|
14
|
+
};
|
|
15
|
+
/**
|
|
16
|
+
* A Share form content which is lazy-loaded.
|
|
17
|
+
* Make sure this component is not exported inside main entry points `src/index.ts`
|
|
18
|
+
*/
|
|
19
|
+
declare function LazyShareForm(props: LazyShareFormProps): jsx.JSX.Element;
|
|
20
|
+
export default LazyShareForm;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { default } from './LazyShareForm';
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import { WrappedComponentProps } from 'react-intl-next';
|
|
3
|
+
export interface Props {
|
|
4
|
+
children: React.ReactChild;
|
|
5
|
+
}
|
|
6
|
+
declare const _default: React.FC<import("react-intl-next").WithIntlProps<Props & WrappedComponentProps<"intl">>> & {
|
|
7
|
+
WrappedComponent: React.ComponentType<Props & WrappedComponentProps<"intl">>;
|
|
8
|
+
};
|
|
9
|
+
export default _default;
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import { Appearance } from '@atlaskit/button/types';
|
|
3
|
+
export type Props = {
|
|
4
|
+
appearance?: Appearance;
|
|
5
|
+
iconBefore?: React.ReactChild;
|
|
6
|
+
isLoading?: boolean;
|
|
7
|
+
isSelected?: boolean;
|
|
8
|
+
isDisabled?: boolean;
|
|
9
|
+
onClick: (e: React.MouseEvent<HTMLElement>) => void;
|
|
10
|
+
text?: React.ReactNode;
|
|
11
|
+
};
|
|
12
|
+
export declare const ShareButton: React.ForwardRefExoticComponent<Props & React.RefAttributes<HTMLElement>>;
|
|
13
|
+
export default ShareButton;
|
|
@@ -0,0 +1,57 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import { AnalyticsEventPayload, WithAnalyticsEventsProps } from '@atlaskit/analytics-next';
|
|
3
|
+
import { ShortenRequest } from '../clients/AtlassianUrlShortenerClient';
|
|
4
|
+
import { ConfigResponse } from '../clients/ShareServiceClient';
|
|
5
|
+
import type { OriginTracing, OriginTracingFactory, ShareData, ShareDialogContainerProps } from '../types';
|
|
6
|
+
export declare const defaultConfig: ConfigResponse;
|
|
7
|
+
export type State = {
|
|
8
|
+
config?: ConfigResponse;
|
|
9
|
+
isFetchingConfig: boolean;
|
|
10
|
+
shareActionCount: number;
|
|
11
|
+
currentPageUrl: string;
|
|
12
|
+
shortenedCopyLink: null | string;
|
|
13
|
+
shortenedCopyLinkData?: ShortenRequest;
|
|
14
|
+
};
|
|
15
|
+
/**
|
|
16
|
+
* This component serves as a Provider to provide customizable implementations
|
|
17
|
+
* to ShareDialogTrigger component
|
|
18
|
+
*/
|
|
19
|
+
export declare class ShareDialogContainerInternal extends React.Component<WithAnalyticsEventsProps & ShareDialogContainerProps, State> {
|
|
20
|
+
private shareClient;
|
|
21
|
+
private urlShortenerClient;
|
|
22
|
+
private _isMounted;
|
|
23
|
+
private _urlShorteningRequestCounter;
|
|
24
|
+
private _lastUrlShorteningWasTooSlow;
|
|
25
|
+
static defaultProps: {
|
|
26
|
+
enableSmartUserPicker: boolean;
|
|
27
|
+
shareeAction: "view" | "edit";
|
|
28
|
+
product: string;
|
|
29
|
+
};
|
|
30
|
+
constructor(props: ShareDialogContainerProps);
|
|
31
|
+
componentDidMount(): void;
|
|
32
|
+
componentWillUnmount(): void;
|
|
33
|
+
componentDidUpdate(prevProps: ShareDialogContainerProps): void;
|
|
34
|
+
private createAndFireEvent;
|
|
35
|
+
fetchConfig: () => void;
|
|
36
|
+
handleSubmitShare: ({ users, comment }: ShareData) => Promise<void>;
|
|
37
|
+
handleDialogOpen: () => Promise<void>;
|
|
38
|
+
decorateAnalytics: (payload: AnalyticsEventPayload) => AnalyticsEventPayload;
|
|
39
|
+
getUniqueCopyLinkOriginTracing: import("memoize-one").MemoizedFn<(link: string, originTracingFactory: OriginTracingFactory) => OriginTracing>;
|
|
40
|
+
getUniqueFormShareOriginTracing: import("memoize-one").MemoizedFn<(link: string, originTracingFactory: OriginTracingFactory, shareCount: number) => OriginTracing>;
|
|
41
|
+
getUpToDateShortenedCopyLink: (data: ShortenRequest, originId: string) => Promise<string | null>;
|
|
42
|
+
getRawLink(): string;
|
|
43
|
+
getCopyLinkOriginTracing(): OriginTracing;
|
|
44
|
+
getFormShareOriginTracing(): OriginTracing;
|
|
45
|
+
getFullCopyLink(): string;
|
|
46
|
+
shouldShortenCopyLink(): boolean;
|
|
47
|
+
getShortenedCopyLink(): string | undefined;
|
|
48
|
+
getCopyLink(): string;
|
|
49
|
+
updateShortCopyLink(): void;
|
|
50
|
+
getFormShareLink: () => string;
|
|
51
|
+
render(): JSX.Element;
|
|
52
|
+
}
|
|
53
|
+
export declare const ShareDialogContainer: React.ForwardRefExoticComponent<Pick<Omit<WithAnalyticsEventsProps & ShareDialogContainerProps, keyof WithAnalyticsEventsProps>, "onTriggerButtonClick" | "isAutoOpenDialog" | "shouldCloseOnEscapePress" | "dialogPlacement" | "loadUserOptions" | "onDialogOpen" | "onDialogClose" | "onUserSelectionChange" | "renderCustomTriggerButton" | "shareContentType" | "shareFormTitle" | "shareFormHelperMessage" | "showFlags" | "loggedInAccountId" | "triggerButtonAppearance" | "triggerButtonIcon" | "triggerButtonStyle" | "triggerButtonTooltipPosition" | "triggerButtonTooltipText" | "cloudId" | "bottomMessage" | "customFooter" | "isCopyDisabled" | "isPublicLink" | "integrationMode" | "shareFieldsFooter" | "shareIntegrations" | "shareAri" | "tabIndex" | "copyTooltipText" | "dialogZIndex" | "orgId" | "isBrowseUsersDisabled" | "shareClient" | "urlShortenerClient" | "shortLinkData" | "formatCopyLink" | "originTracingFactory" | "productId" | "shareLink" | "shareTitle" | "useUrlShortener"> & Partial<Pick<Omit<WithAnalyticsEventsProps & ShareDialogContainerProps, keyof WithAnalyticsEventsProps>, "enableSmartUserPicker" | "product" | "shareeAction">> & Partial<Pick<{
|
|
54
|
+
enableSmartUserPicker: boolean;
|
|
55
|
+
shareeAction: "view" | "edit";
|
|
56
|
+
product: string;
|
|
57
|
+
}, never>> & React.RefAttributes<any>>;
|
|
@@ -0,0 +1,43 @@
|
|
|
1
|
+
/** @jsx jsx */
|
|
2
|
+
import React from 'react';
|
|
3
|
+
import { jsx } from '@emotion/react';
|
|
4
|
+
import { WrappedComponentProps } from 'react-intl-next';
|
|
5
|
+
import { WithAnalyticsEventsProps } from '@atlaskit/analytics-next';
|
|
6
|
+
import { TriggerProps } from '@atlaskit/popup';
|
|
7
|
+
import { Integration, ShareData, ShareDialogWithTriggerProps, ShareDialogWithTriggerStates } from '../types';
|
|
8
|
+
export declare const defaultShareContentState: ShareData;
|
|
9
|
+
type ShareDialogWithTriggerInternalProps = ShareDialogWithTriggerProps & WrappedComponentProps & WithAnalyticsEventsProps;
|
|
10
|
+
export declare class ShareDialogWithTriggerInternal extends React.PureComponent<ShareDialogWithTriggerInternalProps, ShareDialogWithTriggerStates> {
|
|
11
|
+
static defaultProps: Partial<ShareDialogWithTriggerProps>;
|
|
12
|
+
private containerRef;
|
|
13
|
+
/**
|
|
14
|
+
* Because the PopUp component has a higher zIndex it causes
|
|
15
|
+
* the select to be rendered within it, and add scrollbars.
|
|
16
|
+
* We will render the select options the PopUp outside,
|
|
17
|
+
*/
|
|
18
|
+
private selectPortalRef;
|
|
19
|
+
private start;
|
|
20
|
+
state: ShareDialogWithTriggerStates;
|
|
21
|
+
componentDidMount(): void;
|
|
22
|
+
componentDidUpdate(prevProps: ShareDialogWithTriggerProps): void;
|
|
23
|
+
private closeAndResetDialog;
|
|
24
|
+
private createAndFireEvent;
|
|
25
|
+
private onTabChange;
|
|
26
|
+
private getFlags;
|
|
27
|
+
private setIsLoading;
|
|
28
|
+
private focus;
|
|
29
|
+
private handleKeyDown;
|
|
30
|
+
private handleDialogOpen;
|
|
31
|
+
private onTriggerClick;
|
|
32
|
+
private handleCloseDialog;
|
|
33
|
+
private handleShareSubmit;
|
|
34
|
+
private handleFormDismiss;
|
|
35
|
+
handleCopyLink: () => void;
|
|
36
|
+
handleIntegrationClick: (integration: Integration) => void;
|
|
37
|
+
renderShareTriggerButton: (triggerProps: TriggerProps) => React.ReactNode;
|
|
38
|
+
handleOpenSplitButton: () => void;
|
|
39
|
+
handleCloseSplitButton: () => void;
|
|
40
|
+
render(): jsx.JSX.Element;
|
|
41
|
+
}
|
|
42
|
+
export declare const ShareDialogWithTrigger: React.ComponentType<ShareDialogWithTriggerProps>;
|
|
43
|
+
export {};
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
/** @jsx jsx */
|
|
2
|
+
import React from 'react';
|
|
3
|
+
import { WrappedComponentProps } from 'react-intl-next';
|
|
4
|
+
import { FormChildrenArgs, ShareData, ShareFormProps, TabType } from '../types';
|
|
5
|
+
export declare const formWrapperStyles: import("@emotion/react").SerializedStyles;
|
|
6
|
+
export declare const formFooterStyles: import("@emotion/react").SerializedStyles;
|
|
7
|
+
export type State = {
|
|
8
|
+
selectedTab: TabType;
|
|
9
|
+
};
|
|
10
|
+
export type InternalFormProps = FormChildrenArgs<ShareData> & ShareFormProps & WrappedComponentProps;
|
|
11
|
+
export declare const ShareForm: React.FC<ShareFormProps>;
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { ReactNode } from 'react';
|
|
2
|
+
import { ShareDialogWithTriggerProps } from '../../types';
|
|
3
|
+
export type ShareFormWrapperProps = Pick<ShareDialogWithTriggerProps, 'shareFormTitle'> & {
|
|
4
|
+
shouldShowTitle?: boolean;
|
|
5
|
+
children?: ReactNode;
|
|
6
|
+
footer?: ReactNode;
|
|
7
|
+
};
|
|
8
|
+
declare const ShareFormWrapper: ({ shareFormTitle, shouldShowTitle, children, footer, }: ShareFormWrapperProps) => JSX.Element;
|
|
9
|
+
export default ShareFormWrapper;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { default as ShareFormWrapper } from './ShareFormWrapper';
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
/** @jsx jsx */
|
|
2
|
+
import React from 'react';
|
|
3
|
+
export declare const InlineDialogFormWrapper: React.FC;
|
|
4
|
+
/**
|
|
5
|
+
* Apply the same styling, as previous @atlaskit/inline-dialog had,
|
|
6
|
+
* compared to the @atlaskit/popup we are now using.
|
|
7
|
+
*
|
|
8
|
+
* packages/design-system/inline-dialog/src/InlineDialog/styled.ts:20:3
|
|
9
|
+
*/
|
|
10
|
+
export declare const InlineDialogContentWrapper: React.FC;
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
/** @jsx jsx */
|
|
2
|
+
import React from 'react';
|
|
3
|
+
import { Theme } from '@emotion/react';
|
|
4
|
+
export type Props = {
|
|
5
|
+
title?: React.ReactNode;
|
|
6
|
+
};
|
|
7
|
+
export declare const getFormHeaderTitleStyles: (theme: Theme) => import("@emotion/react").SerializedStyles;
|
|
8
|
+
export declare const ShareHeader: React.StatelessComponent<Props>;
|