@pushwoosh/dumb-components 0.0.16 → 0.0.17

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.
@@ -3,7 +3,7 @@ import { Spacing } from '@pushwoosh/kit-constants';
3
3
  import { Vertical } from '@pushwoosh/kit-helpers';
4
4
  import pwLogo from './assets/PW_logo.svg';
5
5
  import { Container, PreviewMock } from './styled';
6
- import { LockedText, LockedTitle } from '../../../styles';
6
+ import { LockedText, LockedTitle } from '../../../common';
7
7
  export const NoEmailTemplatePreview = () => {
8
8
  return React.createElement(Container, {
9
9
  "$gap": Spacing.S4,
package/index.d.ts CHANGED
@@ -1,6 +1,7 @@
1
1
  export { ProgressBar } from './ProgressBar';
2
2
  export * from './Tabs';
3
3
  export { StatisticCard } from './StatisticCard';
4
- export { EmailTemplatePreview, NoEmailTemplatePreview } from './EmailTemplatePreview';
4
+ export { EmailTemplatePreview, NoEmailTemplatePreview, } from './EmailTemplatePreview';
5
5
  export { PushPreview } from './PushPreview';
6
6
  export { ExportResult } from './ExportResult';
7
+ export { NativeInput, NativeTextarea, NativeSelect, } from './native';
package/index.js CHANGED
@@ -3,4 +3,5 @@ export * from './Tabs';
3
3
  export { StatisticCard } from './StatisticCard';
4
4
  export { EmailTemplatePreview, NoEmailTemplatePreview } from './EmailTemplatePreview';
5
5
  export { PushPreview } from './PushPreview';
6
- export { ExportResult } from './ExportResult';
6
+ export { ExportResult } from './ExportResult';
7
+ export { NativeInput, NativeTextarea, NativeSelect } from './native';
@@ -0,0 +1,3 @@
1
+ export declare const NativeInput: import("styled-components").StyledComponent<"input", any, {
2
+ $isErrored?: boolean;
3
+ }, never>;
@@ -0,0 +1,8 @@
1
+ import styled from 'styled-components';
2
+ import { Color, FontSize, LineHeight, Spacing, ShapeRadius, UnitSize } from '@pushwoosh/kit-constants';
3
+ export const NativeInput = styled.input.withConfig({
4
+ displayName: "NativeInput",
5
+ componentId: "sc-oqkcxd-0"
6
+ })(["height:", ";padding:0 calc(", " - 1px);border:1px solid ", ";border-radius:", ";font-size:", ";line-height:", ";background-color:", ";&:focus{outline:none;border-color:", ";}&:disabled{background-color:", ";}&::placeholder{color:", ";}"], UnitSize.FIELD_HEIGHT, Spacing.S4, ({
7
+ $isErrored
8
+ }) => $isErrored ? Color.DANGER : Color.FORM, ShapeRadius.CONTROL, FontSize.REGULAR, LineHeight.REGULAR, Color.CLEAR, Color.BRIGHT, Color.FROZEN, Color.PHANTOM);
@@ -0,0 +1,3 @@
1
+ export declare const NativeSelect: import("styled-components").StyledComponent<"select", any, {
2
+ $isErrored?: boolean;
3
+ }, never>;
@@ -0,0 +1,10 @@
1
+ import styled from 'styled-components';
2
+ import { Color, FontSize, ShapeRadius, Spacing, UnitSize } from '@pushwoosh/kit-constants';
3
+ export const NativeSelect = styled.select.withConfig({
4
+ displayName: "NativeSelect",
5
+ componentId: "sc-1fsh619-0"
6
+ })(["height:", ";padding:0 ", " 0 ", ";border:1px solid ", ";border-radius:", ";font-size:", ";color:", ";background-color:", ";background-image:linear-gradient(45deg,transparent 50%,currentColor 50%),linear-gradient(135deg,currentColor 50%,transparent 50%);background-position:calc(100% - 16px) calc(1em + 1px),calc(100% - 11px) calc(1em + 1px);background-size:5px 5px;background-repeat:no-repeat;appearance:none;&:hover{border-color:", ";}&:focus{outline:none;border:1px solid ", ";}&:read-only{border:1px solid ", ";}&:disabled{background-color:", ";cursor:not-allowed;}&:read-only{border:1px solid ", ";}&:read-only:hover{border-color:", ";}&::placeholder{color:", ";}"], UnitSize.FIELD_HEIGHT, Spacing.S7, Spacing.S4, Color.FORM, ShapeRadius.CONTROL, FontSize.REGULAR, Color.MAIN, Color.CLEAR, Color.PHANTOM, Color.BRIGHT, Color.FORM, Color.FROZEN, ({
7
+ $isErrored
8
+ }) => $isErrored ? Color.DANGER : Color.FORM, ({
9
+ $isErrored
10
+ }) => $isErrored ? Color.DANGER : Color.PHANTOM, Color.PHANTOM);
@@ -0,0 +1,3 @@
1
+ export declare const NativeTextarea: import("styled-components").StyledComponent<"textarea", any, {
2
+ $isErrored?: boolean;
3
+ }, never>;
@@ -0,0 +1,8 @@
1
+ import styled from 'styled-components';
2
+ import { Color, FontSize, LineHeight, Spacing, ShapeRadius } from '@pushwoosh/kit-constants';
3
+ export const NativeTextarea = styled.textarea.withConfig({
4
+ displayName: "NativeTextarea",
5
+ componentId: "sc-1xe83i4-0"
6
+ })(["min-height:56px;padding:", " ", ";border:1px solid ", ";border-radius:", ";font-size:", ";line-height:", ";background-color:", ";&:focus{outline:none;border-color:", ";}&:disabled{background-color:", ";}&::placeholder{color:", ";}"], Spacing.S3, Spacing.S4, ({
7
+ $isErrored
8
+ }) => $isErrored ? Color.DANGER : Color.FORM, ShapeRadius.CONTROL, FontSize.REGULAR, LineHeight.REGULAR, Color.CLEAR, Color.BRIGHT, Color.FROZEN, Color.PHANTOM);
@@ -0,0 +1,3 @@
1
+ export { NativeInput } from './Input';
2
+ export { NativeTextarea } from './Textarea';
3
+ export { NativeSelect } from './Select';
@@ -0,0 +1,3 @@
1
+ export { NativeInput } from './Input';
2
+ export { NativeTextarea } from './Textarea';
3
+ export { NativeSelect } from './Select';
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@pushwoosh/dumb-components",
3
- "version": "0.0.16",
3
+ "version": "0.0.17",
4
4
  "description": "React components to build Pushwoosh products",
5
5
  "main": "index.js",
6
6
  "module": "index.js",
package/styles.d.ts DELETED
@@ -1,8 +0,0 @@
1
- import { H5 } from '@pushwoosh/kit-typography';
2
- export declare const LockedTitle: import("styled-components").StyledComponent<typeof H5, any, {
3
- $uppercase?: boolean;
4
- }, never>;
5
- export declare const LockedText: import("styled-components").StyledComponent<"div", any, {
6
- $uppercase?: boolean;
7
- $small?: boolean;
8
- }, never>;
package/styles.js DELETED
@@ -1,17 +0,0 @@
1
- import styled from 'styled-components';
2
- import { Color, FontSize } from '@pushwoosh/kit-constants';
3
- import { H5 } from '@pushwoosh/kit-typography';
4
- export const LockedTitle = styled(H5).withConfig({
5
- displayName: "LockedTitle",
6
- componentId: "sc-86bd6t-0"
7
- })(["text-transform:", ";color:", ";text-overflow:ellipsis;"], ({
8
- $uppercase
9
- }) => $uppercase ? 'uppercase' : 'initial', Color.LOCKED);
10
- export const LockedText = styled.div.withConfig({
11
- displayName: "LockedText",
12
- componentId: "sc-86bd6t-1"
13
- })(["text-transform:", ";font-size:", ";color:", ";"], ({
14
- $uppercase
15
- }) => $uppercase ? 'uppercase' : 'initial', ({
16
- $small
17
- }) => $small ? FontSize.SMALL : 'initial', Color.LOCKED);