@7shifts/sous-chef 1.5.8 → 2.1.1

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,16 @@
1
+ import React from 'react';
2
+ import type { SelectOption, SelectOptions } from '../../forms/SelectField/types';
3
+ declare type Props<T> = {
4
+ name: string;
5
+ value?: SelectOption<T>;
6
+ placeholder?: string;
7
+ options: SelectOptions<T>;
8
+ onChange?: (e: SelectOption<T>) => void;
9
+ onBlur?: (e: SelectOption<T>) => void;
10
+ disabled?: boolean;
11
+ /** Use a prefix for things like icons or symbols (“$”, “¥”, “£”). */
12
+ prefix: React.ReactNode;
13
+ };
14
+ /** Toolbar component to make a possible selection from predefined options. */
15
+ declare const ToolbarSelect: <T extends unknown>({ name, value, options, onChange, onBlur, placeholder, disabled, prefix, }: Props<T>) => JSX.Element;
16
+ export default ToolbarSelect;
@@ -0,0 +1,5 @@
1
+ declare type GetSelectStylesControls = {
2
+ wrapToNextLine?: boolean;
3
+ };
4
+ export declare const getSelectStyles: ({ wrapToNextLine }: GetSelectStylesControls) => Object;
5
+ export {};
@@ -1,8 +1,7 @@
1
1
  declare type GetSelectStylesControls = {
2
2
  isInvalid: boolean;
3
- hasPrefix?: boolean;
4
3
  asToolbarFilter?: boolean;
5
4
  wrapToNextLine?: boolean;
6
5
  };
7
- export declare const getSelectStyles: ({ isInvalid, hasPrefix, asToolbarFilter, wrapToNextLine }: GetSelectStylesControls) => Object;
6
+ export declare const getSelectStyles: ({ isInvalid, asToolbarFilter, wrapToNextLine }: GetSelectStylesControls) => Object;
8
7
  export {};
@@ -23,5 +23,5 @@ declare type Props = {
23
23
  suffix?: React.ReactNode;
24
24
  value?: string;
25
25
  };
26
- declare const _default: React.ForwardRefExoticComponent<Props & React.RefAttributes<HTMLInputElement>>;
27
- export default _default;
26
+ declare const TextField: React.ForwardRefExoticComponent<Props & React.RefAttributes<HTMLInputElement>>;
27
+ export default TextField;
@@ -1,2 +1,8 @@
1
1
  import { IconSize } from './types';
2
- export declare const getIconStyles: (size: IconSize, rotate?: number | undefined) => Object;
2
+ declare type Params = {
3
+ size?: IconSize;
4
+ color?: string;
5
+ styles?: Object;
6
+ };
7
+ export declare const getIconStyles: ({ size, color, styles }: Params) => Object;
8
+ export {};
@@ -1,22 +1 @@
1
- import IconArrowDown from './IconArrowDown';
2
- import IconArrowLeft from './IconArrowLeft';
3
- import IconArrowRight from './IconArrowRight';
4
- import IconArrowUp from './IconArrowUp';
5
- import IconCalendar from './IconCalendar';
6
- import IconCheck from './IconCheck';
7
- import IconChevronDown from './IconChevronDown';
8
- import IconChevronUp from './IconChevronUp';
9
- import IconClose from './IconClose';
10
- import IconComment from './IconComment';
11
- import IconDelete from './IconDelete';
12
- import IconEdit from './IconEdit';
13
- import IconEye from './IconEye';
14
- import IconEyeSlash from './IconEyeSlash';
15
- import IconExclaim from './IconExclaim';
16
- import IconLocation from './IconLocation';
17
- import IconMinusCircle from './IconMinusCircle';
18
- import IconMore from './IconMore';
19
- import IconRemove from './IconRemove';
20
- import IconUser from './IconUser';
21
- import IconUserPlus from './IconUserPlus';
22
- export { IconArrowDown, IconArrowLeft, IconArrowRight, IconArrowUp, IconCalendar, IconCheck, IconChevronDown, IconChevronUp, IconClose, IconComment, IconDelete, IconEdit, IconEye, IconEyeSlash, IconExclaim, IconLocation, IconMinusCircle, IconMore, IconRemove, IconUser, IconUserPlus };
1
+ export * from './components';
package/dist/index.css CHANGED
@@ -1,14 +1,3 @@
1
- /* stylelint-disable color-no-hex */
2
- /*
3
- These are the colour variables to be used around the webapp.
4
- The variables are set up to describe the color and number which represents the lightness of the color.
5
- The smaller the number the lighter the color. So $eggplant-100 would be light purple and $eggplant-600 would be dark purple.
6
- The base colour is the default colour and is numbered with 400. If someone says "use Tangerine" they are referring to the base color.
7
- Please ask a designer if you have questions about which colours to use.
8
- */
9
- ._f-GkY {
10
- fill: #929292;
11
- }
12
1
  /*********************************
13
2
  For new colours, see _colors.scss.
14
3
  **********************************/
@@ -795,6 +784,7 @@ Please ask a designer if you have questions about which colours to use.
795
784
  ._azbIG {
796
785
  width: 40px;
797
786
  padding: 16px;
787
+ box-sizing: content-box;
798
788
  }
799
789
  /*********************************
800
790
  For new colours, see _colors.scss.
@@ -841,6 +831,7 @@ Please ask a designer if you have questions about which colours to use.
841
831
 
842
832
  ._LoIvx {
843
833
  width: 40px;
834
+ box-sizing: content-box;
844
835
  }
845
836
 
846
837
  ._3VjFP {
@@ -981,6 +972,9 @@ Please ask a designer if you have questions about which colours to use.
981
972
  margin-bottom: auto;
982
973
  text-align: left;
983
974
  }
975
+ ._eX5OL svg {
976
+ color: #929292;
977
+ }
984
978
 
985
979
  .__YH01 {
986
980
  position: absolute;
@@ -1002,6 +996,9 @@ Please ask a designer if you have questions about which colours to use.
1002
996
  right: 0;
1003
997
  text-align: right;
1004
998
  }
999
+ .__YH01 svg {
1000
+ color: #929292;
1001
+ }
1005
1002
  /*********************************
1006
1003
  For new colours, see _colors.scss.
1007
1004
  **********************************/
@@ -1156,6 +1153,7 @@ Please ask a designer if you have questions about which colours to use.
1156
1153
  }
1157
1154
  ._20YOA:disabled {
1158
1155
  background-color: #f8f8f8;
1156
+ color: #929292;
1159
1157
  }
1160
1158
 
1161
1159
  ._3kUSh {
@@ -1166,6 +1164,7 @@ Please ask a designer if you have questions about which colours to use.
1166
1164
  border-left: 0 !important;
1167
1165
  border-top-left-radius: 0 !important;
1168
1166
  border-bottom-left-radius: 0 !important;
1167
+ color: #929292;
1169
1168
  }
1170
1169
 
1171
1170
  ._QXJOD {
@@ -1311,7 +1310,7 @@ input:checked ~ ._1i2AX {
1311
1310
  input:disabled + ._1i2AX {
1312
1311
  background-color: #f8f8f8;
1313
1312
  border-color: #f8f8f8;
1314
- color: #c1c1c1;
1313
+ color: #929292;
1315
1314
  }
1316
1315
  input:disabled:checked + ._1i2AX {
1317
1316
  background-color: #e16840;
@@ -1462,6 +1461,7 @@ Please ask a designer if you have questions about which colours to use.
1462
1461
  }
1463
1462
  ._18Rzv:disabled {
1464
1463
  background-color: #f8f8f8;
1464
+ color: #929292;
1465
1465
  }
1466
1466
 
1467
1467
  ._3eD7t {
@@ -1472,6 +1472,7 @@ Please ask a designer if you have questions about which colours to use.
1472
1472
  border-left: 0 !important;
1473
1473
  border-top-left-radius: 0 !important;
1474
1474
  border-bottom-left-radius: 0 !important;
1475
+ color: #929292;
1475
1476
  }
1476
1477
 
1477
1478
  ._-MgeO {
@@ -1547,6 +1548,7 @@ Please ask a designer if you have questions about which colours to use.
1547
1548
  }
1548
1549
  ._1btTx:disabled, ._1Sc9D:disabled {
1549
1550
  background-color: #f8f8f8;
1551
+ color: #929292;
1550
1552
  }
1551
1553
 
1552
1554
  ._2feYp, ._2SNat {
@@ -1557,6 +1559,7 @@ Please ask a designer if you have questions about which colours to use.
1557
1559
  border-left: 0 !important;
1558
1560
  border-top-left-radius: 0 !important;
1559
1561
  border-bottom-left-radius: 0 !important;
1562
+ color: #929292;
1560
1563
  }
1561
1564
 
1562
1565
  ._27J43, ._3eTNi {
@@ -2037,6 +2040,7 @@ Please ask a designer if you have questions about which colours to use.
2037
2040
  }
2038
2041
  ._25rf7:disabled, ._3qVhi input:disabled, ._3qVhi:disabled {
2039
2042
  background-color: #f8f8f8;
2043
+ color: #929292;
2040
2044
  }
2041
2045
 
2042
2046
  ._2M9Ud {
@@ -2047,6 +2051,7 @@ Please ask a designer if you have questions about which colours to use.
2047
2051
  border-left: 0 !important;
2048
2052
  border-top-left-radius: 0 !important;
2049
2053
  border-bottom-left-radius: 0 !important;
2054
+ color: #929292;
2050
2055
  }
2051
2056
 
2052
2057
  ._foqL0 {
@@ -2064,6 +2069,9 @@ Please ask a designer if you have questions about which colours to use.
2064
2069
  ._3df9R {
2065
2070
  border-color: #e76767 !important;
2066
2071
  }
2072
+ ._2Nkht {
2073
+ background-color: #f8f8f8;
2074
+ }
2067
2075
  ._3qVhi input {
2068
2076
  border: none;
2069
2077
  min-width: 20px;
package/dist/index.d.ts CHANGED
@@ -1,7 +1,7 @@
1
- export * from './icons';
2
1
  export * from './core';
3
2
  export * from './forms';
4
3
  export * from './feedback';
5
4
  export * from './actions';
6
5
  export * from './overlay';
7
6
  export * from './media';
7
+ export * from './icons';