@atlaskit/help 7.2.14 → 7.2.16
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/dist/cjs/analytics.js +1 -1
- package/dist/cjs/components/Article/ArticleLoadingFail/index.js +1 -1
- package/dist/cjs/components/Article/HelpArticle/WasHelpfulForm/WasHelpfulNoButton.js +1 -1
- package/dist/cjs/components/Article/HelpArticle/WasHelpfulForm/WasHelpfulYesButton.js +1 -1
- package/dist/cjs/components/Article/HelpArticle/WasHelpfulForm/index.js +25 -21
- package/dist/cjs/components/Article/HelpArticle/index.js +1 -1
- package/dist/cjs/components/Article/WhatsNewArticle/index.js +1 -1
- package/dist/cjs/components/ArticlesList/ArticlesListItem/index.js +1 -1
- package/dist/cjs/components/ArticlesList/styled.js +2 -2
- package/dist/cjs/components/HelpContentButton/index.js +1 -1
- package/dist/cjs/components/RelatedArticles/index.js +8 -4
- package/dist/cjs/components/RelatedArticles/styled.js +2 -2
- package/dist/cjs/components/Search/SearchInput/index.js +11 -8
- package/dist/cjs/components/WhatsNew/WhatsNewButton/index.js +1 -1
- package/dist/cjs/components/WhatsNew/WhatsNewResults/WhatsNewResultsList/WhatsNewResultItem/index.js +1 -1
- package/dist/cjs/components/WhatsNew/WhatsNewResults/WhatsNewResultsList/styled.js +2 -2
- package/dist/cjs/util/styled.js +2 -2
- package/dist/es2019/analytics.js +1 -1
- package/dist/es2019/components/Article/ArticleLoadingFail/index.js +1 -1
- package/dist/es2019/components/Article/HelpArticle/WasHelpfulForm/WasHelpfulNoButton.js +1 -1
- package/dist/es2019/components/Article/HelpArticle/WasHelpfulForm/WasHelpfulYesButton.js +1 -1
- package/dist/es2019/components/Article/HelpArticle/WasHelpfulForm/index.js +25 -21
- package/dist/es2019/components/Article/HelpArticle/index.js +1 -1
- package/dist/es2019/components/Article/WhatsNewArticle/index.js +1 -1
- package/dist/es2019/components/ArticlesList/ArticlesListItem/index.js +1 -1
- package/dist/es2019/components/ArticlesList/styled.js +1 -1
- package/dist/es2019/components/HelpContentButton/index.js +1 -1
- package/dist/es2019/components/RelatedArticles/index.js +8 -4
- package/dist/es2019/components/RelatedArticles/styled.js +1 -1
- package/dist/es2019/components/Search/SearchInput/index.js +11 -8
- package/dist/es2019/components/WhatsNew/WhatsNewButton/index.js +1 -1
- package/dist/es2019/components/WhatsNew/WhatsNewResults/WhatsNewResultsList/WhatsNewResultItem/index.js +1 -1
- package/dist/es2019/components/WhatsNew/WhatsNewResults/WhatsNewResultsList/styled.js +1 -1
- package/dist/es2019/util/styled.js +1 -1
- package/dist/esm/analytics.js +1 -1
- package/dist/esm/components/Article/ArticleLoadingFail/index.js +1 -1
- package/dist/esm/components/Article/HelpArticle/WasHelpfulForm/WasHelpfulNoButton.js +1 -1
- package/dist/esm/components/Article/HelpArticle/WasHelpfulForm/WasHelpfulYesButton.js +1 -1
- package/dist/esm/components/Article/HelpArticle/WasHelpfulForm/index.js +25 -21
- package/dist/esm/components/Article/HelpArticle/index.js +1 -1
- package/dist/esm/components/Article/WhatsNewArticle/index.js +1 -1
- package/dist/esm/components/ArticlesList/ArticlesListItem/index.js +1 -1
- package/dist/esm/components/ArticlesList/styled.js +1 -1
- package/dist/esm/components/HelpContentButton/index.js +1 -1
- package/dist/esm/components/RelatedArticles/index.js +8 -4
- package/dist/esm/components/RelatedArticles/styled.js +1 -1
- package/dist/esm/components/Search/SearchInput/index.js +11 -8
- package/dist/esm/components/WhatsNew/WhatsNewButton/index.js +1 -1
- package/dist/esm/components/WhatsNew/WhatsNewResults/WhatsNewResultsList/WhatsNewResultItem/index.js +1 -1
- package/dist/esm/components/WhatsNew/WhatsNewResults/WhatsNewResultsList/styled.js +1 -1
- package/dist/esm/util/styled.js +1 -1
- package/dist/types/components/Article/ArticleLoadingFail/styled.d.ts +8 -2
- package/dist/types/components/Article/HelpArticle/WasHelpfulForm/index.d.ts +2 -0
- package/dist/types/components/Article/HelpArticle/WasHelpfulForm/styled.d.ts +12 -3
- package/dist/types/components/Article/WhatsNewArticle/styled.d.ts +24 -6
- package/dist/types/components/Article/styled.d.ts +4 -1
- package/dist/types/components/ArticlesList/ArticlesListItem/styled.d.ts +24 -6
- package/dist/types/components/ArticlesList/styled.d.ts +9 -3
- package/dist/types/components/RelatedArticles/index.d.ts +2 -0
- package/dist/types/components/RelatedArticles/styled.d.ts +17 -5
- package/dist/types/components/Search/SearchInput/index.d.ts +1 -0
- package/dist/types/components/Search/SearchInput/styled.d.ts +12 -3
- package/dist/types/components/Search/SearchResults/styled.d.ts +20 -5
- package/dist/types/components/WhatsNew/WhatsNewResults/WhatsNewResultsEmpty/styled.d.ts +8 -2
- package/dist/types/components/WhatsNew/WhatsNewResults/WhatsNewResultsError/styled.d.ts +8 -2
- package/dist/types/components/WhatsNew/WhatsNewResults/WhatsNewResultsList/WhatsNewResultItem/styled.d.ts +16 -4
- package/dist/types/components/WhatsNew/WhatsNewResults/WhatsNewResultsList/styled.d.ts +17 -5
- package/dist/types/components/WhatsNew/WhatsNewResults/WhatsNewResultsLoading/styled.d.ts +8 -2
- package/dist/types/components/WhatsNew/WhatsNewResults/styled.d.ts +16 -4
- package/dist/types/components/styled.d.ts +12 -3
- package/dist/types/util/styled.d.ts +16 -4
- package/dist/types-ts4.5/components/Article/ArticleLoadingFail/styled.d.ts +8 -2
- package/dist/types-ts4.5/components/Article/HelpArticle/WasHelpfulForm/index.d.ts +2 -0
- package/dist/types-ts4.5/components/Article/HelpArticle/WasHelpfulForm/styled.d.ts +12 -3
- package/dist/types-ts4.5/components/Article/WhatsNewArticle/styled.d.ts +24 -6
- package/dist/types-ts4.5/components/Article/styled.d.ts +4 -1
- package/dist/types-ts4.5/components/ArticlesList/ArticlesListItem/styled.d.ts +24 -6
- package/dist/types-ts4.5/components/ArticlesList/styled.d.ts +9 -3
- package/dist/types-ts4.5/components/RelatedArticles/index.d.ts +2 -0
- package/dist/types-ts4.5/components/RelatedArticles/styled.d.ts +17 -5
- package/dist/types-ts4.5/components/Search/SearchInput/index.d.ts +1 -0
- package/dist/types-ts4.5/components/Search/SearchInput/styled.d.ts +12 -3
- package/dist/types-ts4.5/components/Search/SearchResults/styled.d.ts +20 -5
- package/dist/types-ts4.5/components/WhatsNew/WhatsNewResults/WhatsNewResultsEmpty/styled.d.ts +8 -2
- package/dist/types-ts4.5/components/WhatsNew/WhatsNewResults/WhatsNewResultsError/styled.d.ts +8 -2
- package/dist/types-ts4.5/components/WhatsNew/WhatsNewResults/WhatsNewResultsList/WhatsNewResultItem/styled.d.ts +16 -4
- package/dist/types-ts4.5/components/WhatsNew/WhatsNewResults/WhatsNewResultsList/styled.d.ts +17 -5
- package/dist/types-ts4.5/components/WhatsNew/WhatsNewResults/WhatsNewResultsLoading/styled.d.ts +8 -2
- package/dist/types-ts4.5/components/WhatsNew/WhatsNewResults/styled.d.ts +16 -4
- package/dist/types-ts4.5/components/styled.d.ts +12 -3
- package/dist/types-ts4.5/util/styled.d.ts +16 -4
- package/package.json +6 -6
- package/tmp/api-report-tmp.d.ts +0 -300
|
@@ -59,7 +59,7 @@ export const HelpArticle = ({
|
|
|
59
59
|
analyticsEvent.payload.attributes = {
|
|
60
60
|
componentName: 'Article',
|
|
61
61
|
packageName: "@atlaskit/help",
|
|
62
|
-
packageVersion: "7.2.
|
|
62
|
+
packageVersion: "7.2.16"
|
|
63
63
|
};
|
|
64
64
|
if (onRelatedArticlesShowMoreClick) {
|
|
65
65
|
onRelatedArticlesShowMoreClick(event, analyticsEvent, isCollapsed);
|
|
@@ -13,7 +13,7 @@ import { WhatsNewTypeTitle, WhatsNewTitleText, WhatsNewIconContainer, RelatedLin
|
|
|
13
13
|
const analyticsContextData = {
|
|
14
14
|
componentName: 'ArticlesListItem',
|
|
15
15
|
packageName: "@atlaskit/help",
|
|
16
|
-
packageVersion: "7.2.
|
|
16
|
+
packageVersion: "7.2.16"
|
|
17
17
|
};
|
|
18
18
|
export const WhatsNewArticle = ({
|
|
19
19
|
intl: {
|
|
@@ -7,7 +7,7 @@ import { ArticlesListItemWrapper, ArticlesListItemContainer, ArticlesListItemTit
|
|
|
7
7
|
const ANALYTICS_CONTEXT_DATA = {
|
|
8
8
|
componentName: 'ArticlesListItem',
|
|
9
9
|
packageName: "@atlaskit/help",
|
|
10
|
-
packageVersion: "7.2.
|
|
10
|
+
packageVersion: "7.2.16"
|
|
11
11
|
};
|
|
12
12
|
export const ArticlesListItem = ({
|
|
13
13
|
styles,
|
|
@@ -7,7 +7,7 @@ import { HelpContentButtonContainer, HelpContentButtonIcon, HelpContentButtonTex
|
|
|
7
7
|
const analitycsContextData = {
|
|
8
8
|
componentName: 'HelpContentButton',
|
|
9
9
|
packageName: "@atlaskit/help",
|
|
10
|
-
packageVersion: "7.2.
|
|
10
|
+
packageVersion: "7.2.16"
|
|
11
11
|
};
|
|
12
12
|
const HelpContentButton = ({
|
|
13
13
|
id = '',
|
|
@@ -1,3 +1,6 @@
|
|
|
1
|
+
/** @jsx jsx */
|
|
2
|
+
/** @jsxFrag */
|
|
3
|
+
|
|
1
4
|
import React, { useState, useEffect, useCallback } from 'react';
|
|
2
5
|
import { withAnalyticsContext } from '@atlaskit/analytics-next';
|
|
3
6
|
import SectionMessage from '@atlaskit/section-message';
|
|
@@ -10,8 +13,9 @@ import { DividerLine } from '../../util/styled';
|
|
|
10
13
|
import { RelatedArticlesTitle } from './styled';
|
|
11
14
|
import useCancellablePromise from '../../util/hooks/cancellablePromise';
|
|
12
15
|
import { usePrevious } from '../../util/hooks/previous';
|
|
16
|
+
import { jsx } from '@emotion/react';
|
|
13
17
|
const packageName = "@atlaskit/help";
|
|
14
|
-
const packageVersion = "7.2.
|
|
18
|
+
const packageVersion = "7.2.16";
|
|
15
19
|
export const RelatedArticles = ({
|
|
16
20
|
style = 'primary',
|
|
17
21
|
routeGroup,
|
|
@@ -62,9 +66,9 @@ export const RelatedArticles = ({
|
|
|
62
66
|
}
|
|
63
67
|
}, [prevRouteGroup, prevRouteName, routeGroup, routeName, updateRelatedArticles]);
|
|
64
68
|
if (hasError) {
|
|
65
|
-
return
|
|
69
|
+
return jsx(SectionMessage, {
|
|
66
70
|
appearance: "warning"
|
|
67
|
-
},
|
|
71
|
+
}, jsx("p", null, jsx("strong", null, formatMessage(messages.help_related_article_endpoint_error_title))), jsx("p", null, formatMessage(messages.help_related_article_endpoint_error_description)), jsx("p", null, jsx(Button, {
|
|
68
72
|
appearance: "link",
|
|
69
73
|
spacing: "compact",
|
|
70
74
|
css: {
|
|
@@ -76,7 +80,7 @@ export const RelatedArticles = ({
|
|
|
76
80
|
onClick: updateRelatedArticles
|
|
77
81
|
}, formatMessage(messages.help_related_article_endpoint_error_button_label))));
|
|
78
82
|
} else {
|
|
79
|
-
return
|
|
83
|
+
return jsx(React.Fragment, null, style === 'secondary' && relatedArticles.length > 0 && jsx(React.Fragment, null, jsx(DividerLine, null), jsx(RelatedArticlesTitle, null, formatMessage(messages.help_related_article_title))), isLoading ? jsx(RelatedArticlesLoading, null) : jsx(ArticlesList, {
|
|
80
84
|
style: style,
|
|
81
85
|
articles: relatedArticles,
|
|
82
86
|
onArticlesListItemClick: onRelatedArticlesListItemClick,
|
|
@@ -1,3 +1,5 @@
|
|
|
1
|
+
/** @jsx jsx */
|
|
2
|
+
|
|
1
3
|
import React, { useRef, useCallback } from 'react';
|
|
2
4
|
import { useAnalyticsEvents, AnalyticsContext } from '@atlaskit/analytics-next';
|
|
3
5
|
import Textfield from '@atlaskit/textfield';
|
|
@@ -6,6 +8,7 @@ import { gridSize } from '@atlaskit/theme/constants';
|
|
|
6
8
|
import Spinner from '@atlaskit/spinner';
|
|
7
9
|
import SearchIcon from '@atlaskit/icon/glyph/search';
|
|
8
10
|
import EditorCloseIcon from '@atlaskit/icon/glyph/editor/close';
|
|
11
|
+
import { jsx } from '@emotion/react';
|
|
9
12
|
import { injectIntl } from 'react-intl-next';
|
|
10
13
|
import { REQUEST_STATE } from '../../../model/Requests';
|
|
11
14
|
import { useSearchContext } from '../../contexts/searchContext';
|
|
@@ -14,7 +17,7 @@ import { SearchInputContainer, SearchIconContainer, CloseButtonAndSpinnerContain
|
|
|
14
17
|
const ANALYTICS_CONTEXT_DATA = {
|
|
15
18
|
componentName: 'searchInput',
|
|
16
19
|
packageName: "@atlaskit/help",
|
|
17
|
-
packageVersion: "7.2.
|
|
20
|
+
packageVersion: "7.2.16"
|
|
18
21
|
};
|
|
19
22
|
export const SearchInput = ({
|
|
20
23
|
intl: {
|
|
@@ -69,17 +72,17 @@ export const SearchInput = ({
|
|
|
69
72
|
if (inputRef && inputRef.current) {
|
|
70
73
|
inputRef.current.value = searchValue;
|
|
71
74
|
}
|
|
72
|
-
return
|
|
75
|
+
return jsx(SearchInputContainer, null, jsx(Textfield, {
|
|
73
76
|
title: "Help articles search input",
|
|
74
77
|
autoComplete: "off",
|
|
75
78
|
ref: inputRef,
|
|
76
79
|
name: "help-search-input",
|
|
77
|
-
elemBeforeInput:
|
|
80
|
+
elemBeforeInput: jsx(SearchIconContainer, null, jsx(SearchIcon, {
|
|
78
81
|
label: ""
|
|
79
82
|
})),
|
|
80
|
-
elemAfterInput:
|
|
83
|
+
elemAfterInput: jsx(CloseButtonAndSpinnerContainer, null, searchState === REQUEST_STATE.loading && jsx(Spinner, {
|
|
81
84
|
size: "small"
|
|
82
|
-
}), searchValue !== '' &&
|
|
85
|
+
}), searchValue !== '' && jsx(Button, {
|
|
83
86
|
css: {
|
|
84
87
|
width: `${gridSize() * 3}px`,
|
|
85
88
|
height: `${gridSize() * 3}px`
|
|
@@ -87,7 +90,7 @@ export const SearchInput = ({
|
|
|
87
90
|
appearance: "subtle",
|
|
88
91
|
onClick: handleOnClearButtonClick,
|
|
89
92
|
spacing: "none"
|
|
90
|
-
},
|
|
93
|
+
}, jsx(EditorCloseIcon, {
|
|
91
94
|
label: ""
|
|
92
95
|
}))),
|
|
93
96
|
placeholder: formatMessage(messages.help_search_placeholder),
|
|
@@ -97,8 +100,8 @@ export const SearchInput = ({
|
|
|
97
100
|
}));
|
|
98
101
|
};
|
|
99
102
|
const SearchInputWithContext = props => {
|
|
100
|
-
return
|
|
103
|
+
return jsx(AnalyticsContext, {
|
|
101
104
|
data: ANALYTICS_CONTEXT_DATA
|
|
102
|
-
},
|
|
105
|
+
}, jsx(SearchInput, props));
|
|
103
106
|
};
|
|
104
107
|
export default injectIntl(SearchInputWithContext);
|
|
@@ -11,7 +11,7 @@ import { ARTICLE_TYPE } from '../../../model/Help';
|
|
|
11
11
|
const ANALYTICS_CONTEXT_DATA = {
|
|
12
12
|
componentName: 'WhatsNewButton',
|
|
13
13
|
packageName: "@atlaskit/help",
|
|
14
|
-
packageVersion: "7.2.
|
|
14
|
+
packageVersion: "7.2.16"
|
|
15
15
|
};
|
|
16
16
|
export const WhatsNewButton = ({
|
|
17
17
|
productName,
|
|
@@ -8,7 +8,7 @@ import { WhatsNewResultListItemWrapper, WhatsNewResultListItemTitleContainer, Wh
|
|
|
8
8
|
const ANALYTICS_CONTEXT_DATA = {
|
|
9
9
|
componentName: 'ArticlesListItem',
|
|
10
10
|
packageName: "@atlaskit/help",
|
|
11
|
-
packageVersion: "7.2.
|
|
11
|
+
packageVersion: "7.2.16"
|
|
12
12
|
};
|
|
13
13
|
export const WhatsNewResultListItem = ({
|
|
14
14
|
intl: {
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
/** @jsx jsx */
|
|
2
2
|
|
|
3
|
+
import { keyframes } from '@emotion/react';
|
|
3
4
|
import styled from '@emotion/styled';
|
|
4
5
|
import { gridSize } from '@atlaskit/theme/constants';
|
|
5
6
|
import * as colors from '@atlaskit/theme/colors';
|
|
6
|
-
import { keyframes } from '@emotion/core';
|
|
7
7
|
import { WHATS_NEW_ITEM_TYPES } from '../model/WhatsNew';
|
|
8
8
|
export const DividerLine = styled.div`
|
|
9
9
|
background-color: ${`var(--ds-border, ${colors.N30A})`};
|
package/dist/esm/analytics.js
CHANGED
|
@@ -8,7 +8,7 @@ import { LoadingErrorMessage, LoadingErrorButtonContainer } from './styled';
|
|
|
8
8
|
var ANALYTICS_CONTEXT_DATA = {
|
|
9
9
|
componentName: 'ArticleLoadingFail',
|
|
10
10
|
packageName: "@atlaskit/help",
|
|
11
|
-
packageVersion: "7.2.
|
|
11
|
+
packageVersion: "7.2.16"
|
|
12
12
|
};
|
|
13
13
|
export var ArticleLoadingFail = function ArticleLoadingFail(_ref) {
|
|
14
14
|
var onTryAgainButtonClick = _ref.onTryAgainButtonClick,
|
|
@@ -6,7 +6,7 @@ import { messages } from '../../../../messages';
|
|
|
6
6
|
var ANALYTICS_CONTEXT_DATA = {
|
|
7
7
|
componentName: 'ArticleWasHelpfulNoButton',
|
|
8
8
|
packageName: "@atlaskit/help",
|
|
9
|
-
packageVersion: "7.2.
|
|
9
|
+
packageVersion: "7.2.16"
|
|
10
10
|
};
|
|
11
11
|
export var ArticleWasHelpfulNoButton = function ArticleWasHelpfulNoButton(_ref) {
|
|
12
12
|
var _ref$isSelected = _ref.isSelected,
|
|
@@ -6,7 +6,7 @@ import { messages } from '../../../../messages';
|
|
|
6
6
|
var ANALYTICS_CONTEXT_DATA = {
|
|
7
7
|
componentName: 'ArticleWasHelpfulYesButton',
|
|
8
8
|
packageName: "@atlaskit/help",
|
|
9
|
-
packageVersion: "7.2.
|
|
9
|
+
packageVersion: "7.2.16"
|
|
10
10
|
};
|
|
11
11
|
export var ArticleWasHelpfulYesButton = function ArticleWasHelpfulYesButton(_ref) {
|
|
12
12
|
var _ref$isSelected = _ref.isSelected,
|
|
@@ -1,5 +1,8 @@
|
|
|
1
1
|
import _extends from "@babel/runtime/helpers/extends";
|
|
2
2
|
import _slicedToArray from "@babel/runtime/helpers/slicedToArray";
|
|
3
|
+
/** @jsx jsx */
|
|
4
|
+
/** @jsxFrag */
|
|
5
|
+
|
|
3
6
|
import React, { useState } from 'react';
|
|
4
7
|
import { injectIntl } from 'react-intl-next';
|
|
5
8
|
import { useAnalyticsEvents, AnalyticsContext } from '@atlaskit/analytics-next';
|
|
@@ -14,6 +17,7 @@ import CheckCircleIcon from '@atlaskit/icon/glyph/check-circle';
|
|
|
14
17
|
// AFP-2532 TODO: Fix automatic suppressions below
|
|
15
18
|
// eslint-disable-next-line @atlassian/tangerine/import/entry-points
|
|
16
19
|
import { colors } from '@atlaskit/theme';
|
|
20
|
+
import { jsx } from '@emotion/react';
|
|
17
21
|
import { messages } from '../../../../messages';
|
|
18
22
|
import ArticleWasHelpfulYesButton from './WasHelpfulYesButton';
|
|
19
23
|
import ArticleWasHelpfulNoButton from './WasHelpfulNoButton';
|
|
@@ -22,7 +26,7 @@ var FEEDBACK_REASON_TEXT_MAX_LENGTH = '16000';
|
|
|
22
26
|
var ANALYTICS_CONTEXT_DATA = {
|
|
23
27
|
componentName: 'ArticleWasHelpfulForm',
|
|
24
28
|
packageName: "@atlaskit/help",
|
|
25
|
-
packageVersion: "7.2.
|
|
29
|
+
packageVersion: "7.2.16"
|
|
26
30
|
};
|
|
27
31
|
export var ArticleWasHelpfulForm = function ArticleWasHelpfulForm(_ref) {
|
|
28
32
|
var onWasHelpfulSubmit = _ref.onWasHelpfulSubmit,
|
|
@@ -137,75 +141,75 @@ export var ArticleWasHelpfulForm = function ArticleWasHelpfulForm(_ref) {
|
|
|
137
141
|
};
|
|
138
142
|
if (!wasHelpfulFormSubmitedFailed) {
|
|
139
143
|
if ((handleArticleWasHelpfulYesButtonClick || handleArticleWasHelpfulNoButtonClick) && !wasHelpfulFormSubmited) {
|
|
140
|
-
return
|
|
144
|
+
return jsx(React.Fragment, null, jsx(ArticleFeedbackContainer, null, jsx(ArticleFeedbackText, {
|
|
141
145
|
style: {
|
|
142
146
|
paddingRight: "var(--ds-space-100, 8px)"
|
|
143
147
|
}
|
|
144
|
-
}, formatMessage(messages.help_article_rating_title)),
|
|
148
|
+
}, formatMessage(messages.help_article_rating_title)), jsx(ButtonGroup, null, handleArticleWasHelpfulYesButtonClick && jsx(ArticleWasHelpfulYesButton, {
|
|
145
149
|
onClick: handleArticleWasHelpfulYesButtonClick,
|
|
146
150
|
isSelected: wasHelpful === true
|
|
147
|
-
}), handleArticleWasHelpfulNoButtonClick &&
|
|
151
|
+
}), handleArticleWasHelpfulNoButtonClick && jsx(ArticleWasHelpfulNoButton, {
|
|
148
152
|
onClick: handleArticleWasHelpfulNoButtonClick,
|
|
149
153
|
isSelected: wasHelpful === false
|
|
150
|
-
}))), wasHelpful !== null && onWasHelpfulSubmit &&
|
|
154
|
+
}))), wasHelpful !== null && onWasHelpfulSubmit && jsx(ArticleFeedbackAnswerWrapper, null, jsx(Form, {
|
|
151
155
|
onSubmit: onFeedbackSubmitClick
|
|
152
156
|
}, function (_ref2) {
|
|
153
157
|
var formProps = _ref2.formProps;
|
|
154
|
-
return
|
|
158
|
+
return jsx("form", _extends({}, formProps, {
|
|
155
159
|
name: "form-example"
|
|
156
|
-
}),
|
|
160
|
+
}), jsx(ArticleFeedbackText, null, formatMessage(messages.help_article_rating_form_title)), !wasHelpful && jsx(Field, {
|
|
157
161
|
name: "feedbackReason",
|
|
158
162
|
isRequired: true
|
|
159
163
|
}, function (_ref3) {
|
|
160
164
|
var fieldProps = _ref3.fieldProps;
|
|
161
|
-
return
|
|
165
|
+
return jsx(RadioGroup, _extends({}, fieldProps, {
|
|
162
166
|
options: negativeFeedbackReason,
|
|
163
167
|
onChange: radioGroupReasonOnChange
|
|
164
168
|
}));
|
|
165
|
-
}),
|
|
169
|
+
}), jsx(Field, {
|
|
166
170
|
name: "feedbackReasonText",
|
|
167
171
|
defaultValue: ""
|
|
168
172
|
}, function (_ref4) {
|
|
169
173
|
var fieldProps = _ref4.fieldProps;
|
|
170
|
-
return
|
|
174
|
+
return jsx(TextArea, _extends({}, fieldProps, {
|
|
171
175
|
minimumRows: 4,
|
|
172
176
|
maxLength: FEEDBACK_REASON_TEXT_MAX_LENGTH,
|
|
173
177
|
value: feedbackReasonText,
|
|
174
178
|
onChange: feedbackReasonTextOnChange
|
|
175
179
|
}));
|
|
176
|
-
}),
|
|
180
|
+
}), jsx(CheckboxField, {
|
|
177
181
|
name: "contactMe"
|
|
178
182
|
}, function (_ref5) {
|
|
179
183
|
var fieldProps = _ref5.fieldProps;
|
|
180
|
-
return
|
|
184
|
+
return jsx(Checkbox, _extends({}, fieldProps, {
|
|
181
185
|
isChecked: contactMe,
|
|
182
186
|
onChange: checkboxContactMeOnChange,
|
|
183
187
|
label: formatMessage(messages.help_article_rating_form_contact_me)
|
|
184
188
|
}));
|
|
185
|
-
}),
|
|
189
|
+
}), jsx(FormFooter, null, jsx(ButtonGroup, null, jsx(Button, {
|
|
186
190
|
type: "submit",
|
|
187
191
|
appearance: "primary",
|
|
188
192
|
isDisabled: !wasHelpful && feedbackReason === '',
|
|
189
193
|
isLoading: wasHelpfulFormSubmitLoading
|
|
190
|
-
}, formatMessage(messages.help_article_rating_form_submit)),
|
|
194
|
+
}, formatMessage(messages.help_article_rating_form_submit)), jsx(Button, {
|
|
191
195
|
onClick: onFeedbackSubmitCancel
|
|
192
196
|
}, formatMessage(messages.help_article_rating_form_cancel)))));
|
|
193
197
|
})));
|
|
194
198
|
} else if (wasHelpfulFormSubmited && wasHelpful === null) {
|
|
195
|
-
return
|
|
199
|
+
return jsx(ArticleFeedbackContainer, null, jsx("span", {
|
|
196
200
|
style: {
|
|
197
201
|
paddingRight: "var(--ds-space-100, 8px)",
|
|
198
202
|
verticalAlign: 'middle'
|
|
199
203
|
}
|
|
200
|
-
},
|
|
204
|
+
}, jsx(CheckCircleIcon, {
|
|
201
205
|
primaryColor: "var(--ds-icon-success, ".concat(colors.G400, ")"),
|
|
202
206
|
label: ""
|
|
203
|
-
})),
|
|
207
|
+
})), jsx(ArticleFeedbackText, null, formatMessage(messages.help_article_rating_form_Success)));
|
|
204
208
|
}
|
|
205
209
|
} else if (wasHelpfulFormSubmited && wasHelpfulFormSubmitedFailed) {
|
|
206
|
-
return
|
|
210
|
+
return jsx(React.Fragment, null, wasHelpfulFormSubmited && wasHelpfulFormSubmitedFailed && jsx(ArticleFeedbackContainer, null, jsx(SectionMessage, {
|
|
207
211
|
appearance: "warning"
|
|
208
|
-
},
|
|
212
|
+
}, jsx("p", null, formatMessage(messages.help_article_rating_form_failed)), jsx("p", null, jsx(Button, {
|
|
209
213
|
appearance: "link",
|
|
210
214
|
spacing: "compact",
|
|
211
215
|
css: {
|
|
@@ -220,8 +224,8 @@ export var ArticleWasHelpfulForm = function ArticleWasHelpfulForm(_ref) {
|
|
|
220
224
|
return null;
|
|
221
225
|
};
|
|
222
226
|
var ArticleWasHelpfulFormWithContext = function ArticleWasHelpfulFormWithContext(props) {
|
|
223
|
-
return
|
|
227
|
+
return jsx(AnalyticsContext, {
|
|
224
228
|
data: ANALYTICS_CONTEXT_DATA
|
|
225
|
-
},
|
|
229
|
+
}, jsx(ArticleWasHelpfulForm, props));
|
|
226
230
|
};
|
|
227
231
|
export default injectIntl(ArticleWasHelpfulFormWithContext);
|
|
@@ -55,7 +55,7 @@ export var HelpArticle = function HelpArticle(_ref) {
|
|
|
55
55
|
analyticsEvent.payload.attributes = {
|
|
56
56
|
componentName: 'Article',
|
|
57
57
|
packageName: "@atlaskit/help",
|
|
58
|
-
packageVersion: "7.2.
|
|
58
|
+
packageVersion: "7.2.16"
|
|
59
59
|
};
|
|
60
60
|
if (onRelatedArticlesShowMoreClick) {
|
|
61
61
|
onRelatedArticlesShowMoreClick(event, analyticsEvent, isCollapsed);
|
|
@@ -13,7 +13,7 @@ import { WhatsNewTypeTitle, WhatsNewTitleText, WhatsNewIconContainer, RelatedLin
|
|
|
13
13
|
var analyticsContextData = {
|
|
14
14
|
componentName: 'ArticlesListItem',
|
|
15
15
|
packageName: "@atlaskit/help",
|
|
16
|
-
packageVersion: "7.2.
|
|
16
|
+
packageVersion: "7.2.16"
|
|
17
17
|
};
|
|
18
18
|
export var WhatsNewArticle = function WhatsNewArticle(_ref) {
|
|
19
19
|
var formatMessage = _ref.intl.formatMessage,
|
|
@@ -7,7 +7,7 @@ import { ArticlesListItemWrapper, ArticlesListItemContainer, ArticlesListItemTit
|
|
|
7
7
|
var ANALYTICS_CONTEXT_DATA = {
|
|
8
8
|
componentName: 'ArticlesListItem',
|
|
9
9
|
packageName: "@atlaskit/help",
|
|
10
|
-
packageVersion: "7.2.
|
|
10
|
+
packageVersion: "7.2.16"
|
|
11
11
|
};
|
|
12
12
|
export var ArticlesListItem = function ArticlesListItem(_ref) {
|
|
13
13
|
var styles = _ref.styles,
|
|
@@ -2,7 +2,7 @@ import _taggedTemplateLiteral from "@babel/runtime/helpers/taggedTemplateLiteral
|
|
|
2
2
|
var _templateObject, _templateObject2, _templateObject3;
|
|
3
3
|
/** @jsx jsx */
|
|
4
4
|
|
|
5
|
-
import { css } from '@emotion/
|
|
5
|
+
import { css } from '@emotion/react';
|
|
6
6
|
import styled from '@emotion/styled';
|
|
7
7
|
export var truncate = function truncate() {
|
|
8
8
|
var width = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : '100%';
|
|
@@ -7,7 +7,7 @@ import { HelpContentButtonContainer, HelpContentButtonIcon, HelpContentButtonTex
|
|
|
7
7
|
var analitycsContextData = {
|
|
8
8
|
componentName: 'HelpContentButton',
|
|
9
9
|
packageName: "@atlaskit/help",
|
|
10
|
-
packageVersion: "7.2.
|
|
10
|
+
packageVersion: "7.2.16"
|
|
11
11
|
};
|
|
12
12
|
var HelpContentButton = function HelpContentButton(_ref) {
|
|
13
13
|
var _ref$id = _ref.id,
|
|
@@ -1,6 +1,9 @@
|
|
|
1
1
|
import _asyncToGenerator from "@babel/runtime/helpers/asyncToGenerator";
|
|
2
2
|
import _slicedToArray from "@babel/runtime/helpers/slicedToArray";
|
|
3
3
|
import _regeneratorRuntime from "@babel/runtime/regenerator";
|
|
4
|
+
/** @jsx jsx */
|
|
5
|
+
/** @jsxFrag */
|
|
6
|
+
|
|
4
7
|
import React, { useState, useEffect, useCallback } from 'react';
|
|
5
8
|
import { withAnalyticsContext } from '@atlaskit/analytics-next';
|
|
6
9
|
import SectionMessage from '@atlaskit/section-message';
|
|
@@ -13,8 +16,9 @@ import { DividerLine } from '../../util/styled';
|
|
|
13
16
|
import { RelatedArticlesTitle } from './styled';
|
|
14
17
|
import useCancellablePromise from '../../util/hooks/cancellablePromise';
|
|
15
18
|
import { usePrevious } from '../../util/hooks/previous';
|
|
19
|
+
import { jsx } from '@emotion/react';
|
|
16
20
|
var packageName = "@atlaskit/help";
|
|
17
|
-
var packageVersion = "7.2.
|
|
21
|
+
var packageVersion = "7.2.16";
|
|
18
22
|
export var RelatedArticles = function RelatedArticles(_ref) {
|
|
19
23
|
var _ref$style = _ref.style,
|
|
20
24
|
style = _ref$style === void 0 ? 'primary' : _ref$style,
|
|
@@ -91,9 +95,9 @@ export var RelatedArticles = function RelatedArticles(_ref) {
|
|
|
91
95
|
}
|
|
92
96
|
}, [prevRouteGroup, prevRouteName, routeGroup, routeName, updateRelatedArticles]);
|
|
93
97
|
if (hasError) {
|
|
94
|
-
return
|
|
98
|
+
return jsx(SectionMessage, {
|
|
95
99
|
appearance: "warning"
|
|
96
|
-
},
|
|
100
|
+
}, jsx("p", null, jsx("strong", null, formatMessage(messages.help_related_article_endpoint_error_title))), jsx("p", null, formatMessage(messages.help_related_article_endpoint_error_description)), jsx("p", null, jsx(Button, {
|
|
97
101
|
appearance: "link",
|
|
98
102
|
spacing: "compact",
|
|
99
103
|
css: {
|
|
@@ -105,7 +109,7 @@ export var RelatedArticles = function RelatedArticles(_ref) {
|
|
|
105
109
|
onClick: updateRelatedArticles
|
|
106
110
|
}, formatMessage(messages.help_related_article_endpoint_error_button_label))));
|
|
107
111
|
} else {
|
|
108
|
-
return
|
|
112
|
+
return jsx(React.Fragment, null, style === 'secondary' && relatedArticles.length > 0 && jsx(React.Fragment, null, jsx(DividerLine, null), jsx(RelatedArticlesTitle, null, formatMessage(messages.help_related_article_title))), isLoading ? jsx(RelatedArticlesLoading, null) : jsx(ArticlesList, {
|
|
109
113
|
style: style,
|
|
110
114
|
articles: relatedArticles,
|
|
111
115
|
onArticlesListItemClick: onRelatedArticlesListItemClick,
|
|
@@ -2,7 +2,7 @@ import _taggedTemplateLiteral from "@babel/runtime/helpers/taggedTemplateLiteral
|
|
|
2
2
|
var _templateObject, _templateObject2, _templateObject3, _templateObject4, _templateObject5;
|
|
3
3
|
/** @jsx jsx */
|
|
4
4
|
|
|
5
|
-
import { css } from '@emotion/
|
|
5
|
+
import { css } from '@emotion/react';
|
|
6
6
|
import styled from '@emotion/styled';
|
|
7
7
|
import * as colors from '@atlaskit/theme/colors';
|
|
8
8
|
import { fontSize } from '@atlaskit/theme/constants';
|
|
@@ -1,3 +1,5 @@
|
|
|
1
|
+
/** @jsx jsx */
|
|
2
|
+
|
|
1
3
|
import React, { useRef, useCallback } from 'react';
|
|
2
4
|
import { useAnalyticsEvents, AnalyticsContext } from '@atlaskit/analytics-next';
|
|
3
5
|
import Textfield from '@atlaskit/textfield';
|
|
@@ -6,6 +8,7 @@ import { gridSize } from '@atlaskit/theme/constants';
|
|
|
6
8
|
import Spinner from '@atlaskit/spinner';
|
|
7
9
|
import SearchIcon from '@atlaskit/icon/glyph/search';
|
|
8
10
|
import EditorCloseIcon from '@atlaskit/icon/glyph/editor/close';
|
|
11
|
+
import { jsx } from '@emotion/react';
|
|
9
12
|
import { injectIntl } from 'react-intl-next';
|
|
10
13
|
import { REQUEST_STATE } from '../../../model/Requests';
|
|
11
14
|
import { useSearchContext } from '../../contexts/searchContext';
|
|
@@ -14,7 +17,7 @@ import { SearchInputContainer, SearchIconContainer, CloseButtonAndSpinnerContain
|
|
|
14
17
|
var ANALYTICS_CONTEXT_DATA = {
|
|
15
18
|
componentName: 'searchInput',
|
|
16
19
|
packageName: "@atlaskit/help",
|
|
17
|
-
packageVersion: "7.2.
|
|
20
|
+
packageVersion: "7.2.16"
|
|
18
21
|
};
|
|
19
22
|
export var SearchInput = function SearchInput(_ref) {
|
|
20
23
|
var formatMessage = _ref.intl.formatMessage;
|
|
@@ -64,17 +67,17 @@ export var SearchInput = function SearchInput(_ref) {
|
|
|
64
67
|
if (inputRef && inputRef.current) {
|
|
65
68
|
inputRef.current.value = searchValue;
|
|
66
69
|
}
|
|
67
|
-
return
|
|
70
|
+
return jsx(SearchInputContainer, null, jsx(Textfield, {
|
|
68
71
|
title: "Help articles search input",
|
|
69
72
|
autoComplete: "off",
|
|
70
73
|
ref: inputRef,
|
|
71
74
|
name: "help-search-input",
|
|
72
|
-
elemBeforeInput:
|
|
75
|
+
elemBeforeInput: jsx(SearchIconContainer, null, jsx(SearchIcon, {
|
|
73
76
|
label: ""
|
|
74
77
|
})),
|
|
75
|
-
elemAfterInput:
|
|
78
|
+
elemAfterInput: jsx(CloseButtonAndSpinnerContainer, null, searchState === REQUEST_STATE.loading && jsx(Spinner, {
|
|
76
79
|
size: "small"
|
|
77
|
-
}), searchValue !== '' &&
|
|
80
|
+
}), searchValue !== '' && jsx(Button, {
|
|
78
81
|
css: {
|
|
79
82
|
width: "".concat(gridSize() * 3, "px"),
|
|
80
83
|
height: "".concat(gridSize() * 3, "px")
|
|
@@ -82,7 +85,7 @@ export var SearchInput = function SearchInput(_ref) {
|
|
|
82
85
|
appearance: "subtle",
|
|
83
86
|
onClick: handleOnClearButtonClick,
|
|
84
87
|
spacing: "none"
|
|
85
|
-
},
|
|
88
|
+
}, jsx(EditorCloseIcon, {
|
|
86
89
|
label: ""
|
|
87
90
|
}))),
|
|
88
91
|
placeholder: formatMessage(messages.help_search_placeholder),
|
|
@@ -92,8 +95,8 @@ export var SearchInput = function SearchInput(_ref) {
|
|
|
92
95
|
}));
|
|
93
96
|
};
|
|
94
97
|
var SearchInputWithContext = function SearchInputWithContext(props) {
|
|
95
|
-
return
|
|
98
|
+
return jsx(AnalyticsContext, {
|
|
96
99
|
data: ANALYTICS_CONTEXT_DATA
|
|
97
|
-
},
|
|
100
|
+
}, jsx(SearchInput, props));
|
|
98
101
|
};
|
|
99
102
|
export default injectIntl(SearchInputWithContext);
|
|
@@ -11,7 +11,7 @@ import { ARTICLE_TYPE } from '../../../model/Help';
|
|
|
11
11
|
var ANALYTICS_CONTEXT_DATA = {
|
|
12
12
|
componentName: 'WhatsNewButton',
|
|
13
13
|
packageName: "@atlaskit/help",
|
|
14
|
-
packageVersion: "7.2.
|
|
14
|
+
packageVersion: "7.2.16"
|
|
15
15
|
};
|
|
16
16
|
export var WhatsNewButton = function WhatsNewButton(_ref) {
|
|
17
17
|
var productName = _ref.productName,
|
package/dist/esm/components/WhatsNew/WhatsNewResults/WhatsNewResultsList/WhatsNewResultItem/index.js
CHANGED
|
@@ -8,7 +8,7 @@ import { WhatsNewResultListItemWrapper, WhatsNewResultListItemTitleContainer, Wh
|
|
|
8
8
|
var ANALYTICS_CONTEXT_DATA = {
|
|
9
9
|
componentName: 'ArticlesListItem',
|
|
10
10
|
packageName: "@atlaskit/help",
|
|
11
|
-
packageVersion: "7.2.
|
|
11
|
+
packageVersion: "7.2.16"
|
|
12
12
|
};
|
|
13
13
|
export var WhatsNewResultListItem = function WhatsNewResultListItem(_ref) {
|
|
14
14
|
var formatMessage = _ref.intl.formatMessage,
|
|
@@ -2,7 +2,7 @@ import _taggedTemplateLiteral from "@babel/runtime/helpers/taggedTemplateLiteral
|
|
|
2
2
|
var _templateObject, _templateObject2, _templateObject3, _templateObject4, _templateObject5;
|
|
3
3
|
/** @jsx jsx */
|
|
4
4
|
|
|
5
|
-
import { css } from '@emotion/
|
|
5
|
+
import { css } from '@emotion/react';
|
|
6
6
|
import styled from '@emotion/styled';
|
|
7
7
|
import { fontSizeSmall } from '@atlaskit/theme/constants';
|
|
8
8
|
import * as colors from '@atlaskit/theme/colors';
|
package/dist/esm/util/styled.js
CHANGED
|
@@ -2,10 +2,10 @@ import _taggedTemplateLiteral from "@babel/runtime/helpers/taggedTemplateLiteral
|
|
|
2
2
|
var _templateObject, _templateObject2, _templateObject3, _templateObject4, _templateObject5;
|
|
3
3
|
/** @jsx jsx */
|
|
4
4
|
|
|
5
|
+
import { keyframes } from '@emotion/react';
|
|
5
6
|
import styled from '@emotion/styled';
|
|
6
7
|
import { gridSize } from '@atlaskit/theme/constants';
|
|
7
8
|
import * as colors from '@atlaskit/theme/colors';
|
|
8
|
-
import { keyframes } from '@emotion/core';
|
|
9
9
|
import { WHATS_NEW_ITEM_TYPES } from '../model/WhatsNew';
|
|
10
10
|
export var DividerLine = styled.div(_templateObject || (_templateObject = _taggedTemplateLiteral(["\n background-color: ", ";\n height: 2px;\n width: 100%;\n padding: 0 ", ";\n margin-top: ", ";\n box-sizing: border-box;\n"])), "var(--ds-border, ".concat(colors.N30A, ")"), "var(--ds-space-200, 16px)", "var(--ds-space-200, 16px)");
|
|
11
11
|
|
|
@@ -1,3 +1,9 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
|
-
export declare const LoadingErrorMessage: import("@emotion/styled
|
|
3
|
-
|
|
2
|
+
export declare const LoadingErrorMessage: import("@emotion/styled").StyledComponent<{
|
|
3
|
+
theme?: import("@emotion/react").Theme | undefined;
|
|
4
|
+
as?: import("react").ElementType<any> | undefined;
|
|
5
|
+
}, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {}>;
|
|
6
|
+
export declare const LoadingErrorButtonContainer: import("@emotion/styled").StyledComponent<{
|
|
7
|
+
theme?: import("@emotion/react").Theme | undefined;
|
|
8
|
+
as?: import("react").ElementType<any> | undefined;
|
|
9
|
+
}, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {}>;
|