@meduza/ui-kit-2 0.8.628 → 0.8.690

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.
Files changed (46) hide show
  1. package/dist/ListViewSwitcher/ListViewSwitcher.types.d.ts +6 -0
  2. package/dist/ListViewSwitcher/index.d.ts +3 -0
  3. package/dist/Meta/Meta.types.d.ts +0 -1
  4. package/dist/RawHtmlBlock/RawHtmlBlock.types.d.ts +0 -1
  5. package/dist/RenderBlocks/RenderBlocks.types.d.ts +0 -1
  6. package/dist/SvgSymbol/SvgSymbol.types.d.ts +1 -1
  7. package/dist/Switcher/Switcher.types.d.ts +2 -3
  8. package/dist/ToolbarButton/ToolbarButton.types.d.ts +1 -1
  9. package/dist/index.d.ts +1 -0
  10. package/dist/types.d.ts +1 -1
  11. package/dist/ui-kit-2.cjs.development.js +360 -370
  12. package/dist/ui-kit-2.cjs.development.js.map +1 -1
  13. package/dist/ui-kit-2.cjs.production.min.js +1 -1
  14. package/dist/ui-kit-2.cjs.production.min.js.map +1 -1
  15. package/dist/ui-kit-2.esm.js +360 -371
  16. package/dist/ui-kit-2.esm.js.map +1 -1
  17. package/dist/ui-kit-game.css +138 -47
  18. package/dist/ui-kit.css +138 -47
  19. package/package.json +1 -1
  20. package/src/EmbedBlock/EmbedBlock.module.css +9 -0
  21. package/src/EmbedBlock/EmbedBlock.tsx +15 -4
  22. package/src/Image/index.tsx +1 -4
  23. package/src/ListViewSwitcher/ListViewSwitcher.module.css +109 -0
  24. package/src/ListViewSwitcher/ListViewSwitcher.stories.module.css +6 -0
  25. package/src/ListViewSwitcher/ListViewSwitcher.stories.tsx +38 -0
  26. package/src/ListViewSwitcher/ListViewSwitcher.test.tsx +35 -0
  27. package/src/ListViewSwitcher/ListViewSwitcher.types.ts +7 -0
  28. package/src/ListViewSwitcher/index.tsx +30 -0
  29. package/src/Meta/Meta.module.css +0 -16
  30. package/src/Meta/Meta.types.ts +0 -1
  31. package/src/Meta/MetaContainer.tsx +0 -27
  32. package/src/RawHtmlBlock/RawHtmlBlock.types.ts +0 -1
  33. package/src/RawHtmlBlock/index.tsx +1 -3
  34. package/src/RenderBlocks/RenderBlocks.types.ts +0 -1
  35. package/src/RenderBlocks/index.tsx +1 -3
  36. package/src/Spoiler/Spoiler.module.css +10 -9
  37. package/src/SvgSymbol/SvgSymbol.types.ts +0 -2
  38. package/src/Switcher/Switcher.module.css +4 -21
  39. package/src/Switcher/Switcher.stories.module.css +3 -21
  40. package/src/Switcher/Switcher.stories.tsx +13 -32
  41. package/src/Switcher/Switcher.types.ts +2 -4
  42. package/src/Switcher/index.tsx +7 -7
  43. package/src/ToolbarButton/ToolbarButton.types.ts +0 -2
  44. package/src/_storybook/PreviewWrapper/index.tsx +0 -1
  45. package/src/index.tsx +1 -0
  46. package/src/types.ts +0 -3
@@ -0,0 +1,6 @@
1
+ import React from 'react';
2
+ export interface ListViewSwitcherProps {
3
+ enabled: boolean;
4
+ onChange: (e: React.ChangeEvent<HTMLInputElement>) => void;
5
+ size?: 'sm' | 'md';
6
+ }
@@ -0,0 +1,3 @@
1
+ import React from 'react';
2
+ import { ListViewSwitcherProps } from './ListViewSwitcher.types';
3
+ export declare const ListViewSwitcher: React.FC<ListViewSwitcherProps>;
@@ -9,7 +9,6 @@ export interface MetaContainerProps {
9
9
  bookmarkAction?: (service: CallToActions, place: string) => void;
10
10
  lightBox?: () => void;
11
11
  lang: 'ru' | 'en';
12
- type?: any;
13
12
  }
14
13
  export interface MetaProps {
15
14
  onlyOn?: string;
@@ -14,5 +14,4 @@ export interface RawHtmlBlockProps {
14
14
  bookmarkAction?: (service: CallToActions, place: string) => void;
15
15
  lightBox?: LightboxContext | null | undefined;
16
16
  lang?: 'ru' | 'en';
17
- type?: any;
18
17
  }
@@ -8,5 +8,4 @@ export interface RenderBlocksProps {
8
8
  bookmarkAction?: (service: CallToActions, place: string) => void;
9
9
  lightBox?: LightboxContext | null | undefined;
10
10
  lang?: 'ru' | 'en';
11
- type?: any;
12
11
  }
@@ -1,5 +1,5 @@
1
1
  export type SvgSymbolStyleContexts = 'isInFeature' | 'isInCard' | 'isInTopicBlockItem' | 'isInPageStatic' | 'isInMaterialMeta' | 'isInToolbar' | 'isInEpisodeBlock' | 'isInAudioPlayer' | 'isInAudioPanel' | 'isInPlaylist' | 'PodcastMaterial' | 'isInHeader' | 'isInProfile' | 'isInBookmark';
2
- export type Icons = 'meduzaLogo' | 'meduzaSymbol' | 'menu' | 'fb' | 'tw' | 'vk' | 'ok' | 'tg' | 'chat' | 'magic' | 'backward' | 'forward' | 'download' | 'episodeDownload' | 'play' | 'pause' | 'shareBookmark' | 'speedHalf' | 'speedThreeQuarters' | 'speedOne' | 'speedOneQuarter' | 'speedOneHalf' | 'speedTwo' | 'podcastBookmark' | 'reaction' | 'cross' | 'link' | 'search' | 'card' | 'podcast' | 'arrow' | 'brent' | 'user' | 'bookmark' | 'receipt' | 'read' | 'listened';
2
+ export type Icons = 'meduzaLogo' | 'meduzaSymbol' | 'menu' | 'fb' | 'tw' | 'tg' | 'chat' | 'magic' | 'backward' | 'forward' | 'download' | 'episodeDownload' | 'play' | 'pause' | 'shareBookmark' | 'speedHalf' | 'speedThreeQuarters' | 'speedOne' | 'speedOneQuarter' | 'speedOneHalf' | 'speedTwo' | 'podcastBookmark' | 'reaction' | 'cross' | 'link' | 'search' | 'card' | 'podcast' | 'arrow' | 'brent' | 'user' | 'bookmark' | 'receipt' | 'read' | 'listened';
3
3
  export type Sizes = 'small' | 'normal' | 'medium' | 'large' | 'unset';
4
4
  export interface SvgSymbolProps {
5
5
  styleContext?: SvgSymbolStyleContexts;
@@ -1,12 +1,11 @@
1
1
  import React from 'react';
2
2
  export type SwitcherStyleContexts = 'isInLive' | 'isInPanel' | 'isInMenu';
3
3
  export type SwitcherThemes = 'light' | 'dark';
4
- export type SwitcherChildrenPositions = 'left' | 'right';
5
4
  export interface SwitcherProps {
6
5
  enabled: boolean;
7
6
  styleContext: SwitcherStyleContexts;
8
7
  onChange: (e: React.ChangeEvent<HTMLInputElement>) => void;
9
8
  theme?: SwitcherThemes;
10
- children: JSX.Element[] | JSX.Element;
11
- childrenPosition?: SwitcherChildrenPositions;
9
+ childrenLeft?: JSX.Element;
10
+ childrenRight?: JSX.Element;
12
11
  }
@@ -1,4 +1,4 @@
1
- export type ToolbarButtonTypes = 'vk' | 'fb' | 'tw' | 'tg' | 'ok' | 'reaction' | 'pdf' | 'bookmark' | 'unblock' | 'cross';
1
+ export type ToolbarButtonTypes = 'fb' | 'tw' | 'tg' | 'reaction' | 'pdf' | 'bookmark' | 'unblock' | 'cross';
2
2
  export interface ToolbarButtonProps {
3
3
  type: ToolbarButtonTypes;
4
4
  theme?: string;
package/dist/index.d.ts CHANGED
@@ -26,6 +26,7 @@ export * from './HalfBlock';
26
26
  export * from './RawHtmlBlock';
27
27
  export * from './ImportantLead';
28
28
  export * from './ListBlock';
29
+ export * from './ListViewSwitcher';
29
30
  export * from './RelatedBlock';
30
31
  export * from './RichTitle';
31
32
  export * from './SimpleBlock';
package/dist/types.d.ts CHANGED
@@ -4,7 +4,7 @@ export interface OptimizedImageItem {
4
4
  '1x_webp': string;
5
5
  '2x_webp': string;
6
6
  }
7
- export type CallToActions = 'fb' | 'tw' | 'vk' | 'ok' | 'tg' | 'wp' | 'reaction' | 'pdf' | 'bookmark' | 'cross';
7
+ export type CallToActions = 'fb' | 'tw' | 'tg' | 'reaction' | 'pdf' | 'bookmark' | 'cross';
8
8
  export type LightboxImage = {
9
9
  original: string;
10
10
  w325: OptimizedImageItem;