@salutejs/plasma-new-hope 0.176.1-canary.1510.11572230988.0 → 0.176.1-canary.1517.11571952534.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (184) hide show
  1. package/cjs/components/Notification/Notification.css +11 -11
  2. package/cjs/components/Notification/Notification.js +2 -2
  3. package/cjs/components/Notification/Notification.js.map +1 -1
  4. package/cjs/components/Notification/Notification.styles.js +2 -11
  5. package/cjs/components/Notification/Notification.styles.js.map +1 -1
  6. package/cjs/components/Notification/{Notification.styles_e6274r.css → Notification.styles_7h8hp0.css} +2 -2
  7. package/cjs/components/Notification/Notification.tokens.js +1 -2
  8. package/cjs/components/Notification/Notification.tokens.js.map +1 -1
  9. package/cjs/components/Notification/Notification.types.js.map +1 -1
  10. package/cjs/components/Notification/NotificationsPortal.js +4 -8
  11. package/cjs/components/Notification/NotificationsPortal.js.map +1 -1
  12. package/cjs/components/Notification/NotificationsProvider.css +11 -11
  13. package/cjs/components/Notification/NotificationsProvider.js +1 -3
  14. package/cjs/components/Notification/NotificationsProvider.js.map +1 -1
  15. package/cjs/components/Pagination/Pagination.css +12 -12
  16. package/cjs/components/Pagination/ui/PaginationSelectPerPage/PaginationSelectPerPage.css +12 -12
  17. package/cjs/components/Select/Select.css +12 -12
  18. package/cjs/components/Select/Select.tokens.js +1 -2
  19. package/cjs/components/Select/Select.tokens.js.map +1 -1
  20. package/cjs/components/Select/ui/Inner/Inner.css +12 -12
  21. package/cjs/components/Select/ui/Inner/ui/Item/Item.css +12 -12
  22. package/cjs/components/Select/ui/Target/Target.css +12 -12
  23. package/cjs/components/Select/ui/Target/ui/Textfield/Textfield.css +12 -12
  24. package/cjs/components/Select/ui/Target/ui/Textfield/Textfield.styles.js +1 -1
  25. package/cjs/components/Select/ui/Target/ui/Textfield/Textfield.styles.js.map +1 -1
  26. package/{es/components/Select/ui/Target/ui/Textfield/Textfield.styles_jzeap2.css → cjs/components/Select/ui/Target/ui/Textfield/Textfield.styles_11yj58s.css} +1 -1
  27. package/cjs/components/Steps/Steps.css +9 -9
  28. package/cjs/components/Steps/Steps.tokens.js +1 -0
  29. package/cjs/components/Steps/Steps.tokens.js.map +1 -1
  30. package/cjs/components/Steps/ui/StepItem/StepItem.css +9 -9
  31. package/cjs/components/Steps/ui/StepItem/StepItem.js +29 -7
  32. package/cjs/components/Steps/ui/StepItem/StepItem.js.map +1 -1
  33. package/cjs/components/Steps/ui/StepItem/StepItem.styles.js +6 -6
  34. package/cjs/components/Steps/ui/StepItem/StepItem.styles.js.map +1 -1
  35. package/cjs/components/Steps/ui/StepItem/StepItem.styles_1oh5gqm.css +9 -0
  36. package/cjs/index.css +31 -31
  37. package/cjs/index.js +1 -1
  38. package/emotion/cjs/components/Notification/Notification.js +2 -2
  39. package/emotion/cjs/components/Notification/Notification.styles.js +19 -14
  40. package/emotion/cjs/components/Notification/Notification.template-doc.mdx +8 -17
  41. package/emotion/cjs/components/Notification/Notification.tokens.js +1 -2
  42. package/emotion/cjs/components/Notification/NotificationsPortal.js +5 -9
  43. package/emotion/cjs/components/Notification/NotificationsProvider.js +1 -3
  44. package/emotion/cjs/components/Notification/index.js +4 -4
  45. package/emotion/cjs/components/Select/Select.tokens.js +1 -2
  46. package/emotion/cjs/components/Select/ui/Target/ui/Textfield/Textfield.styles.js +21 -12
  47. package/emotion/cjs/components/Steps/Steps.tokens.js +1 -0
  48. package/emotion/cjs/components/Steps/ui/StepItem/StepItem.js +29 -7
  49. package/emotion/cjs/components/Steps/ui/StepItem/StepItem.styles.js +17 -11
  50. package/emotion/cjs/examples/plasma_b2c/components/Notification/Notification.js +3 -5
  51. package/emotion/cjs/examples/plasma_b2c/components/Notification/Notification.stories.tsx +4 -25
  52. package/emotion/cjs/examples/plasma_b2c/components/Steps/Steps.config.js +5 -5
  53. package/emotion/cjs/examples/plasma_b2c/components/Steps/Steps.stories.tsx +1 -1
  54. package/emotion/cjs/examples/plasma_web/components/Notification/Notification.js +3 -5
  55. package/emotion/cjs/examples/plasma_web/components/Notification/Notification.stories.tsx +4 -25
  56. package/emotion/cjs/examples/plasma_web/components/Steps/Steps.config.js +5 -5
  57. package/emotion/cjs/examples/plasma_web/components/Steps/Steps.stories.tsx +1 -1
  58. package/emotion/es/components/Notification/Notification.js +1 -1
  59. package/emotion/es/components/Notification/Notification.styles.js +19 -14
  60. package/emotion/es/components/Notification/Notification.template-doc.mdx +8 -17
  61. package/emotion/es/components/Notification/Notification.tokens.js +1 -2
  62. package/emotion/es/components/Notification/NotificationsPortal.js +5 -9
  63. package/emotion/es/components/Notification/NotificationsProvider.js +1 -3
  64. package/emotion/es/components/Notification/index.js +1 -1
  65. package/emotion/es/components/Select/Select.tokens.js +1 -2
  66. package/emotion/es/components/Select/ui/Target/ui/Textfield/Textfield.styles.js +21 -12
  67. package/emotion/es/components/Steps/Steps.tokens.js +1 -0
  68. package/emotion/es/components/Steps/ui/StepItem/StepItem.js +29 -7
  69. package/emotion/es/components/Steps/ui/StepItem/StepItem.styles.js +17 -11
  70. package/emotion/es/examples/plasma_b2c/components/Notification/Notification.js +4 -6
  71. package/emotion/es/examples/plasma_b2c/components/Notification/Notification.stories.tsx +4 -25
  72. package/emotion/es/examples/plasma_b2c/components/Steps/Steps.config.js +5 -5
  73. package/emotion/es/examples/plasma_b2c/components/Steps/Steps.stories.tsx +1 -1
  74. package/emotion/es/examples/plasma_web/components/Notification/Notification.js +4 -6
  75. package/emotion/es/examples/plasma_web/components/Notification/Notification.stories.tsx +4 -25
  76. package/emotion/es/examples/plasma_web/components/Steps/Steps.config.js +5 -5
  77. package/emotion/es/examples/plasma_web/components/Steps/Steps.stories.tsx +1 -1
  78. package/es/components/Notification/Notification.css +11 -11
  79. package/es/components/Notification/Notification.js +2 -2
  80. package/es/components/Notification/Notification.js.map +1 -1
  81. package/es/components/Notification/Notification.styles.js +2 -11
  82. package/es/components/Notification/Notification.styles.js.map +1 -1
  83. package/es/components/Notification/{Notification.styles_e6274r.css → Notification.styles_7h8hp0.css} +2 -2
  84. package/es/components/Notification/Notification.tokens.js +1 -2
  85. package/es/components/Notification/Notification.tokens.js.map +1 -1
  86. package/es/components/Notification/Notification.types.js.map +1 -1
  87. package/es/components/Notification/NotificationsPortal.js +4 -8
  88. package/es/components/Notification/NotificationsPortal.js.map +1 -1
  89. package/es/components/Notification/NotificationsProvider.css +11 -11
  90. package/es/components/Notification/NotificationsProvider.js +1 -3
  91. package/es/components/Notification/NotificationsProvider.js.map +1 -1
  92. package/es/components/Pagination/Pagination.css +12 -12
  93. package/es/components/Pagination/ui/PaginationSelectPerPage/PaginationSelectPerPage.css +12 -12
  94. package/es/components/Select/Select.css +12 -12
  95. package/es/components/Select/Select.tokens.js +1 -2
  96. package/es/components/Select/Select.tokens.js.map +1 -1
  97. package/es/components/Select/ui/Inner/Inner.css +12 -12
  98. package/es/components/Select/ui/Inner/ui/Item/Item.css +12 -12
  99. package/es/components/Select/ui/Target/Target.css +12 -12
  100. package/es/components/Select/ui/Target/ui/Textfield/Textfield.css +12 -12
  101. package/es/components/Select/ui/Target/ui/Textfield/Textfield.styles.js +1 -1
  102. package/es/components/Select/ui/Target/ui/Textfield/Textfield.styles.js.map +1 -1
  103. package/{cjs/components/Select/ui/Target/ui/Textfield/Textfield.styles_jzeap2.css → es/components/Select/ui/Target/ui/Textfield/Textfield.styles_11yj58s.css} +1 -1
  104. package/es/components/Steps/Steps.css +9 -9
  105. package/es/components/Steps/Steps.tokens.js +1 -0
  106. package/es/components/Steps/Steps.tokens.js.map +1 -1
  107. package/es/components/Steps/ui/StepItem/StepItem.css +9 -9
  108. package/es/components/Steps/ui/StepItem/StepItem.js +30 -8
  109. package/es/components/Steps/ui/StepItem/StepItem.js.map +1 -1
  110. package/es/components/Steps/ui/StepItem/StepItem.styles.js +6 -6
  111. package/es/components/Steps/ui/StepItem/StepItem.styles.js.map +1 -1
  112. package/es/components/Steps/ui/StepItem/StepItem.styles_1oh5gqm.css +9 -0
  113. package/es/index.css +31 -31
  114. package/es/index.js +1 -1
  115. package/package.json +2 -2
  116. package/styled-components/cjs/components/Notification/Notification.js +2 -2
  117. package/styled-components/cjs/components/Notification/Notification.styles.js +2 -5
  118. package/styled-components/cjs/components/Notification/Notification.template-doc.mdx +8 -17
  119. package/styled-components/cjs/components/Notification/Notification.tokens.js +1 -2
  120. package/styled-components/cjs/components/Notification/NotificationsPortal.js +4 -8
  121. package/styled-components/cjs/components/Notification/NotificationsProvider.js +1 -3
  122. package/styled-components/cjs/components/Notification/index.js +4 -4
  123. package/styled-components/cjs/components/Select/Select.tokens.js +1 -2
  124. package/styled-components/cjs/components/Select/ui/Target/ui/Textfield/Textfield.styles.js +1 -1
  125. package/styled-components/cjs/components/Steps/Steps.tokens.js +1 -0
  126. package/styled-components/cjs/components/Steps/ui/StepItem/StepItem.js +29 -7
  127. package/styled-components/cjs/components/Steps/ui/StepItem/StepItem.styles.js +12 -6
  128. package/styled-components/cjs/examples/plasma_b2c/components/Notification/Notification.js +3 -5
  129. package/styled-components/cjs/examples/plasma_b2c/components/Notification/Notification.stories.tsx +4 -25
  130. package/styled-components/cjs/examples/plasma_b2c/components/Steps/Steps.config.js +1 -1
  131. package/styled-components/cjs/examples/plasma_b2c/components/Steps/Steps.stories.tsx +1 -1
  132. package/styled-components/cjs/examples/plasma_web/components/Notification/Notification.js +3 -5
  133. package/styled-components/cjs/examples/plasma_web/components/Notification/Notification.stories.tsx +4 -25
  134. package/styled-components/cjs/examples/plasma_web/components/Steps/Steps.config.js +1 -1
  135. package/styled-components/cjs/examples/plasma_web/components/Steps/Steps.stories.tsx +1 -1
  136. package/styled-components/es/components/Notification/Notification.js +1 -1
  137. package/styled-components/es/components/Notification/Notification.styles.js +2 -5
  138. package/styled-components/es/components/Notification/Notification.template-doc.mdx +8 -17
  139. package/styled-components/es/components/Notification/Notification.tokens.js +1 -2
  140. package/styled-components/es/components/Notification/NotificationsPortal.js +4 -8
  141. package/styled-components/es/components/Notification/NotificationsProvider.js +1 -3
  142. package/styled-components/es/components/Notification/index.js +1 -1
  143. package/styled-components/es/components/Select/Select.tokens.js +1 -2
  144. package/styled-components/es/components/Select/ui/Target/ui/Textfield/Textfield.styles.js +1 -1
  145. package/styled-components/es/components/Steps/Steps.tokens.js +1 -0
  146. package/styled-components/es/components/Steps/ui/StepItem/StepItem.js +29 -7
  147. package/styled-components/es/components/Steps/ui/StepItem/StepItem.styles.js +12 -6
  148. package/styled-components/es/examples/plasma_b2c/components/Notification/Notification.js +4 -6
  149. package/styled-components/es/examples/plasma_b2c/components/Notification/Notification.stories.tsx +4 -25
  150. package/styled-components/es/examples/plasma_b2c/components/Steps/Steps.config.js +1 -1
  151. package/styled-components/es/examples/plasma_b2c/components/Steps/Steps.stories.tsx +1 -1
  152. package/styled-components/es/examples/plasma_web/components/Notification/Notification.js +4 -6
  153. package/styled-components/es/examples/plasma_web/components/Notification/Notification.stories.tsx +4 -25
  154. package/styled-components/es/examples/plasma_web/components/Steps/Steps.config.js +1 -1
  155. package/styled-components/es/examples/plasma_web/components/Steps/Steps.stories.tsx +1 -1
  156. package/types/components/Notification/Notification.d.ts +3 -3
  157. package/types/components/Notification/Notification.d.ts.map +1 -1
  158. package/types/components/Notification/Notification.styles.d.ts +2 -4
  159. package/types/components/Notification/Notification.styles.d.ts.map +1 -1
  160. package/types/components/Notification/Notification.tokens.d.ts +0 -1
  161. package/types/components/Notification/Notification.tokens.d.ts.map +1 -1
  162. package/types/components/Notification/Notification.types.d.ts +5 -11
  163. package/types/components/Notification/Notification.types.d.ts.map +1 -1
  164. package/types/components/Notification/NotificationsPortal.d.ts.map +1 -1
  165. package/types/components/Notification/NotificationsProvider.d.ts +3 -4
  166. package/types/components/Notification/NotificationsProvider.d.ts.map +1 -1
  167. package/types/components/Notification/index.d.ts +2 -2
  168. package/types/components/Notification/index.d.ts.map +1 -1
  169. package/types/components/Select/Select.tokens.d.ts +0 -1
  170. package/types/components/Select/Select.tokens.d.ts.map +1 -1
  171. package/types/components/Select/ui/Target/ui/Textfield/Textfield.styles.d.ts.map +1 -1
  172. package/types/components/Steps/Steps.tokens.d.ts +1 -0
  173. package/types/components/Steps/Steps.tokens.d.ts.map +1 -1
  174. package/types/components/Steps/ui/StepItem/StepItem.d.ts.map +1 -1
  175. package/types/components/Steps/ui/StepItem/StepItem.styles.d.ts +2 -2
  176. package/types/components/Steps/ui/StepItem/StepItem.styles.d.ts.map +1 -1
  177. package/types/examples/plasma_b2c/components/Notification/Notification.d.ts +2 -4
  178. package/types/examples/plasma_b2c/components/Notification/Notification.d.ts.map +1 -1
  179. package/types/examples/plasma_b2c/components/Steps/Steps.config.d.ts.map +1 -1
  180. package/types/examples/plasma_web/components/Notification/Notification.d.ts +13 -4
  181. package/types/examples/plasma_web/components/Notification/Notification.d.ts.map +1 -1
  182. package/types/examples/plasma_web/components/Steps/Steps.config.d.ts.map +1 -1
  183. package/cjs/components/Steps/ui/StepItem/StepItem.styles_sp9rcd.css +0 -9
  184. package/es/components/Steps/ui/StepItem/StepItem.styles_sp9rcd.css +0 -9
@@ -16,16 +16,14 @@ var _engines = /*#__PURE__*/require("../../../../engines");
16
16
  var _Notification2 = /*#__PURE__*/require("./Notification.config");
17
17
  var _Modal = /*#__PURE__*/require("../../../../components/Modal");
18
18
  function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
19
- var mergedConfig = /*#__PURE__*/(0, _engines.mergeConfig)(_Notification.notificationConfig, _Notification2.config);
19
+ var mergedConfig = /*#__PURE__*/(0, _engines.mergeConfig)(_Notification.noticationConfig, _Notification2.config);
20
20
  var Notification = exports.Notification = /*#__PURE__*/(0, _engines.component)(mergedConfig);
21
21
  var NotificationsProvider = exports.NotificationsProvider = function NotificationsProvider(_ref) {
22
22
  var children = _ref.children,
23
23
  _ref$frame = _ref.frame,
24
- frame = _ref$frame === void 0 ? 'theme-root' : _ref$frame,
25
- placement = _ref.placement;
24
+ frame = _ref$frame === void 0 ? 'theme-root' : _ref$frame;
26
25
  return /*#__PURE__*/_react["default"].createElement(_Notification.NotificationsProvider, {
27
26
  config: mergedConfig,
28
- frame: frame,
29
- placement: placement
27
+ frame: frame
30
28
  }, children);
31
29
  };
@@ -5,7 +5,6 @@ import type { StoryObj, Meta } from '@storybook/react';
5
5
  import { Button } from '../Button/Button';
6
6
  import { Modal } from '../Modal/Modal';
7
7
  import {
8
- NotificationPlacement,
9
8
  NotificationIconPlacement,
10
9
  NotificationLayout,
11
10
  addNotification,
@@ -21,7 +20,6 @@ const titles = ['Выполнено', 'Внимание', 'Ошибка'];
21
20
  const texts = ['SSH ключ успешно скопирован', 'Нельзя скопировать SSH ключ', 'Не удалось скопировать SSH ключ'];
22
21
  const size = ['xs', 'xxs'];
23
22
  const iconPlacement = ['top', 'left'];
24
- const notificationsPlacements = ['bottom-right', 'bottom-left'];
25
23
 
26
24
  const longText = `JavaScript frameworks are an essential part of modern front-end web development,
27
25
  providing developers with proven tools for building scalable, interactive web applications.
@@ -51,7 +49,6 @@ interface StoryDefaultProps {
51
49
  layout: NotificationLayout;
52
50
  size: 'xs' | 'xxs';
53
51
  iconPlacement: NotificationIconPlacement;
54
- placement?: NotificationPlacement;
55
52
  }
56
53
 
57
54
  const StoryDefault = ({ title, children, iconPlacement, size, layout, showLeftIcon, ...rest }: StoryDefaultProps) => {
@@ -114,10 +111,9 @@ type StoryLiveDemoProps = ComponentProps<typeof Notification> & {
114
111
  layout: NotificationLayout;
115
112
  size: 'xs' | 'xxs';
116
113
  iconPlacement: NotificationIconPlacement;
117
- placement?: NotificationPlacement;
118
114
  };
119
115
 
120
- const StoryLiveDemo = ({ timeout, placement, ...rest }: StoryLiveDemoProps) => {
116
+ const StoryLiveDemo = ({ timeout, ...rest }: StoryLiveDemoProps) => {
121
117
  const count = useRef(0);
122
118
  const handleClick = useCallback(() => {
123
119
  addNotification({ icon: <IconDisclosureRight />, ...rest, ...getNotificationProps(count.current) }, timeout);
@@ -125,7 +121,7 @@ const StoryLiveDemo = ({ timeout, placement, ...rest }: StoryLiveDemoProps) => {
125
121
  }, [count, rest]);
126
122
 
127
123
  return (
128
- <NotificationsProvider placement={placement}>
124
+ <NotificationsProvider>
129
125
  <Button text="Добавить уведомление" onClick={handleClick} />
130
126
  </NotificationsProvider>
131
127
  );
@@ -139,28 +135,20 @@ export const LiveDemo: StoryObj<StoryLiveDemoProps> = {
139
135
  type: 'select',
140
136
  },
141
137
  },
142
- placement: {
143
- options: notificationsPlacements,
144
- control: {
145
- type: 'select',
146
- },
147
- },
148
138
  },
149
139
  args: {
150
140
  timeout: 3000,
151
141
  role: 'alert',
152
142
  layout: 'vertical',
153
- placement: 'bottom-right',
154
143
  },
155
144
  render: (args) => <StoryLiveDemo {...args} />,
156
145
  };
157
146
 
158
147
  type StoryWithModalProps = ComponentProps<typeof Notification> & {
159
148
  timeout: number;
160
- placement?: NotificationPlacement;
161
149
  };
162
150
 
163
- const StoryWithModal = ({ timeout, placement }: StoryWithModalProps) => {
151
+ const StoryWithModal = ({ timeout }: StoryWithModalProps) => {
164
152
  const [isModalOpen, setIsModalOpen] = useState(false);
165
153
  const count = useRef(0);
166
154
  const handleClick = useCallback(() => {
@@ -169,7 +157,7 @@ const StoryWithModal = ({ timeout, placement }: StoryWithModalProps) => {
169
157
  }, [count]);
170
158
 
171
159
  return (
172
- <NotificationsProvider placement={placement}>
160
+ <NotificationsProvider>
173
161
  <PopupProvider>
174
162
  <Button text="Open modal" onClick={() => setIsModalOpen(true)} />
175
163
  <Modal frame="theme-root" opened={isModalOpen} onClose={() => setIsModalOpen(false)}>
@@ -184,15 +172,6 @@ const StoryWithModal = ({ timeout, placement }: StoryWithModalProps) => {
184
172
  export const WithModal: StoryObj<StoryLiveDemoProps> = {
185
173
  args: {
186
174
  timeout: 3500,
187
- placement: 'bottom-right',
188
- },
189
- argTypes: {
190
- placement: {
191
- options: notificationsPlacements,
192
- control: {
193
- type: 'select',
194
- },
195
- },
196
175
  },
197
176
  render: (args) => <StoryWithModal {...args} />,
198
177
  };