@pushwoosh/dumb-components 1.0.70 → 1.0.71

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.
@@ -0,0 +1,3 @@
1
+ import { type ReactElement } from 'react';
2
+ import type { GetStartedPageProps } from './types';
3
+ export declare function GetStartedPage(props: GetStartedPageProps): ReactElement;
@@ -0,0 +1,40 @@
1
+ import React from 'react';
2
+ import { Color } from '@pushwoosh/kit-constants';
3
+ import { Vertical } from '@pushwoosh/kit-helpers';
4
+ import { CheckRoundIcon, LockIcon } from '@pushwoosh/kit-icons';
5
+ import { H1, Paragraph } from '@pushwoosh/kit-typography';
6
+ import { Banner } from '../Banner';
7
+ import { GradientBackground, Wrapper, ContentBox, UnorderedList, UnorderedListItem, UnorderedListIcon, UnorderedListText, Image } from './styles';
8
+ export function GetStartedPage(props) {
9
+ const {
10
+ title,
11
+ description,
12
+ image,
13
+ helpText,
14
+ checkList = [],
15
+ actions = null
16
+ } = props;
17
+ return React.createElement(GradientBackground, null, React.createElement(Wrapper, null, React.createElement(ContentBox, null, React.createElement(Vertical, {
18
+ "$gap": 16
19
+ }, React.createElement(Vertical, {
20
+ "$gap": 4
21
+ }, React.createElement(H1, null, title), React.createElement(Paragraph, null, description)), !!checkList.length && React.createElement(UnorderedList, null, checkList.map(text => React.createElement(UnorderedListItem, {
22
+ key: `item-${text}`
23
+ }, React.createElement(UnorderedListIcon, null, React.createElement(CheckRoundIcon, {
24
+ color: Color.SUCCESS,
25
+ size: "small",
26
+ type: "fill",
27
+ view: "filled"
28
+ })), React.createElement(UnorderedListText, null, text))))), helpText && React.createElement(Banner, {
29
+ type: "info",
30
+ view: "ghost",
31
+ title: helpText,
32
+ icon: React.createElement(LockIcon, {
33
+ view: "filled",
34
+ size: "small"
35
+ })
36
+ }), actions && !helpText && actions), React.createElement(Image, {
37
+ alt: title,
38
+ src: image
39
+ })));
40
+ }
@@ -0,0 +1,2 @@
1
+ export { GetStartedPage } from './GetStartedPage';
2
+ export type { GetStartedPageProps } from './types';
@@ -0,0 +1 @@
1
+ export { GetStartedPage } from './GetStartedPage';
@@ -1,6 +1,13 @@
1
- export declare const RootBox: import("styled-components").StyledComponent<"div", any, {}, never>;
1
+ export declare const GradientBackground: import("styled-components").StyledComponent<"div", any, {}, never>;
2
+ export declare const Wrapper: import("styled-components").StyledComponent<"div", any, {}, never>;
2
3
  export declare const ContentBox: import("styled-components").StyledComponent<"div", any, {}, never>;
3
4
  export declare const UnorderedList: import("styled-components").StyledComponent<"ul", any, {}, never>;
4
5
  export declare const UnorderedListItem: import("styled-components").StyledComponent<"li", any, {}, never>;
6
+ export declare const UnorderedListText: import("styled-components").StyledComponent<"span", any, {
7
+ $color?: string | undefined;
8
+ $uppercase?: boolean | undefined;
9
+ $ellipsis?: boolean | undefined;
10
+ $variant?: import("@pushwoosh/kit-typography").TypographyVariant | undefined;
11
+ }, never>;
5
12
  export declare const UnorderedListIcon: import("styled-components").StyledComponent<"div", any, {}, never>;
6
13
  export declare const Image: import("styled-components").StyledComponent<"img", any, {}, never>;
@@ -0,0 +1,35 @@
1
+ import styled from 'styled-components';
2
+ import { Color, UnitSize } from '@pushwoosh/kit-constants';
3
+ import { Text } from '@pushwoosh/kit-typography';
4
+ export const GradientBackground = styled.div.withConfig({
5
+ displayName: "GradientBackground",
6
+ componentId: "sc-6jf7u0-0"
7
+ })(["display:flex;align-items:center;justify-content:center;width:100%;height:100vh;background:linear-gradient(98.98deg,#F4F9FD 0%,#CBD7FF 100%);"]);
8
+ export const Wrapper = styled.div.withConfig({
9
+ displayName: "Wrapper",
10
+ componentId: "sc-6jf7u0-1"
11
+ })(["display:flex;align-items:center;justify-content:center;width:", ";gap:40px;"], UnitSize.PAGE_WIDTH);
12
+ export const ContentBox = styled.div.withConfig({
13
+ displayName: "ContentBox",
14
+ componentId: "sc-6jf7u0-2"
15
+ })(["display:flex;flex-direction:column;width:340px;gap:24px;"]);
16
+ export const UnorderedList = styled.ul.withConfig({
17
+ displayName: "UnorderedList",
18
+ componentId: "sc-6jf7u0-3"
19
+ })(["display:flex;flex-direction:column;padding:0;margin:0;list-style:none;gap:8px;"]);
20
+ export const UnorderedListItem = styled.li.withConfig({
21
+ displayName: "UnorderedListItem",
22
+ componentId: "sc-6jf7u0-4"
23
+ })(["display:flex;gap:8px;"]);
24
+ export const UnorderedListText = styled(Text).withConfig({
25
+ displayName: "UnorderedListText",
26
+ componentId: "sc-6jf7u0-5"
27
+ })(["padding:4px 0;"]);
28
+ export const UnorderedListIcon = styled.div.withConfig({
29
+ displayName: "UnorderedListIcon",
30
+ componentId: "sc-6jf7u0-6"
31
+ })(["display:flex;align-items:center;justify-content:center;width:28px;height:28px;background:", ";border-radius:50%;padding:4px;"], Color.SUCCESS_LIGHT);
32
+ export const Image = styled.img.withConfig({
33
+ displayName: "Image",
34
+ componentId: "sc-6jf7u0-7"
35
+ })(["width:400px;"]);
@@ -0,0 +1,9 @@
1
+ import type { ReactNode } from 'react';
2
+ export interface GetStartedPageProps {
3
+ title: string;
4
+ description: string;
5
+ image: string;
6
+ helpText?: string;
7
+ checkList?: string[];
8
+ actions?: ReactNode;
9
+ }
package/index.d.ts CHANGED
@@ -6,7 +6,7 @@ export { Checkbox } from './Checkbox';
6
6
  export { Drawer, DrawerHeader, DrawerTitle, DrawerBody, DrawerDocs, useDocs, } from './Drawer';
7
7
  export { DatePicker, DatePickerField, DateTimePicker, DateTimePickerField, } from './DateTimePicker';
8
8
  export { DropdownMenu, DropdownMenuButton, DropdownMenuSection, DropdownMenuItem, } from './DropdownMenu';
9
- export { EmptyPage } from './EmptyPage';
9
+ export { GetStartedPage } from './GetStartedPage';
10
10
  export { EditableField } from './EditableField';
11
11
  export { InputFile } from './InputFile';
12
12
  export { Modal, ModalTitle, ModalConfirm, ModalConfirmProvider, useModalConfirm, ModalHeader, ModalBodyGroup, ModalBodyItem, ModalBody, ModalFooter, } from './Modal';
package/index.js CHANGED
@@ -6,7 +6,7 @@ export { Checkbox } from './Checkbox';
6
6
  export { Drawer, DrawerHeader, DrawerTitle, DrawerBody, DrawerDocs, useDocs } from './Drawer';
7
7
  export { DatePicker, DatePickerField, DateTimePicker, DateTimePickerField } from './DateTimePicker';
8
8
  export { DropdownMenu, DropdownMenuButton, DropdownMenuSection, DropdownMenuItem } from './DropdownMenu';
9
- export { EmptyPage } from './EmptyPage';
9
+ export { GetStartedPage } from './GetStartedPage';
10
10
  export { EditableField } from './EditableField';
11
11
  export { InputFile } from './InputFile';
12
12
  export { Modal, ModalTitle, ModalConfirm, ModalConfirmProvider, useModalConfirm, ModalHeader, ModalBodyGroup, ModalBodyItem, ModalBody, ModalFooter } from './Modal';
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@pushwoosh/dumb-components",
3
- "version": "1.0.70",
3
+ "version": "1.0.71",
4
4
  "description": "React components to build Pushwoosh products",
5
5
  "main": "index.js",
6
6
  "module": "index.js",
@@ -1,3 +0,0 @@
1
- import { type ReactElement } from 'react';
2
- import type { EmptyPageProps } from './types';
3
- export declare function EmptyPage(props: EmptyPageProps): ReactElement;
@@ -1,30 +0,0 @@
1
- import React from 'react';
2
- import { Color } from '@pushwoosh/kit-constants';
3
- import { Vertical } from '@pushwoosh/kit-helpers';
4
- import { CheckRoundIcon } from '@pushwoosh/kit-icons';
5
- import { H1, Paragraph } from '@pushwoosh/kit-typography';
6
- import { RootBox, ContentBox, UnorderedList, UnorderedListItem, UnorderedListIcon, Image } from './styles';
7
- export function EmptyPage(props) {
8
- const {
9
- title,
10
- description,
11
- checkList = [],
12
- image,
13
- actions
14
- } = props;
15
- return React.createElement(RootBox, null, React.createElement(ContentBox, null, React.createElement(Vertical, {
16
- "$gap": 16
17
- }, React.createElement(Vertical, {
18
- "$gap": 4
19
- }, React.createElement(H1, null, title), React.createElement(Paragraph, null, description)), !!checkList.length && React.createElement(UnorderedList, null, checkList.map(text => React.createElement(UnorderedListItem, {
20
- key: `item-${text}`
21
- }, React.createElement(UnorderedListIcon, null, React.createElement(CheckRoundIcon, {
22
- color: Color.SUCCESS,
23
- size: "small",
24
- type: "fill",
25
- view: "filled"
26
- })), text)))), actions), React.createElement(Image, {
27
- alt: title,
28
- src: image
29
- }));
30
- }
@@ -1,2 +0,0 @@
1
- export { EmptyPage } from './EmptyPage';
2
- export type { EmptyPageProps } from './types';
@@ -1 +0,0 @@
1
- export { EmptyPage } from './EmptyPage';
@@ -1,26 +0,0 @@
1
- import styled from 'styled-components';
2
- import { UnitSize } from '@pushwoosh/kit-constants';
3
- export const RootBox = styled.div.withConfig({
4
- displayName: "RootBox",
5
- componentId: "sc-rxhe82-0"
6
- })(["display:flex;align-items:center;justify-content:center;width:", ";gap:40px;"], UnitSize.PAGE_WIDTH);
7
- export const ContentBox = styled.div.withConfig({
8
- displayName: "ContentBox",
9
- componentId: "sc-rxhe82-1"
10
- })(["display:flex;flex-direction:column;width:340px;gap:24px;"]);
11
- export const UnorderedList = styled.ul.withConfig({
12
- displayName: "UnorderedList",
13
- componentId: "sc-rxhe82-2"
14
- })(["display:flex;flex-direction:column;padding:0;margin:0;list-style:none;gap:8px;"]);
15
- export const UnorderedListItem = styled.li.withConfig({
16
- displayName: "UnorderedListItem",
17
- componentId: "sc-rxhe82-3"
18
- })(["display:flex;align-items:center;gap:8px;"]);
19
- export const UnorderedListIcon = styled.div.withConfig({
20
- displayName: "UnorderedListIcon",
21
- componentId: "sc-rxhe82-4"
22
- })(["display:flex;align-items:center;justify-content:center;width:28px;height:28px;background:#64DB2C24;border-radius:50%;padding:4px;"]);
23
- export const Image = styled.img.withConfig({
24
- displayName: "Image",
25
- componentId: "sc-rxhe82-5"
26
- })(["max-width:380px;"]);
@@ -1,8 +0,0 @@
1
- import type { ReactNode } from 'react';
2
- export interface EmptyPageProps {
3
- title: string;
4
- description: string;
5
- checkList: string[];
6
- image: string;
7
- actions: ReactNode;
8
- }
File without changes