@seeqdev/qomponents 0.0.19 → 0.0.20

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.
@@ -11,7 +11,7 @@
11
11
  },
12
12
  "dependencies": {
13
13
  "@fortawesome/fontawesome-free": "^6.4.0",
14
- "@seeqdev/qomponents": "0.0.15",
14
+ "@seeqdev/qomponents": "0.0.20",
15
15
  "react": "^18.2.0",
16
16
  "react-dom": "^18.2.0"
17
17
  },
@@ -53,7 +53,9 @@ function Example() {
53
53
  <b>A note on CSS:</b> Seeq's qomponents come fully styled and ready to use. While it is tempting to use the
54
54
  available <i>extraClassNames</i> property to provide yet additional styling we strongly advise you to use this
55
55
  property to provide only width, margins and padding. This will ensure for a smooth upgrade experience when
56
- Seeq's look and feel changes.
56
+ Seeq's look and feel changes. <br />
57
+ Tip: to indicate missing or wrong user input use the <i>showError</i> property available on TextField,
58
+ TextArea, as well as Select.
57
59
  </p>
58
60
  <p>
59
61
  Using FontAwesome? You can pass FontAwesome Icons to the qomponent Icon component
@@ -83,9 +85,10 @@ function Example() {
83
85
  <div className="formRow">
84
86
  <div className="labelWidth">AddOn Name</div>
85
87
  <TextField
86
- placeholder="provide a name"
88
+ placeholder="you must enter a name"
87
89
  extraClassNames="formElementWidth"
88
90
  value={textFieldValue}
91
+ showError={textFieldValue === ''}
89
92
  onChange={(e: React.ChangeEvent<HTMLInputElement>) => setTextFieldValue(e.target.value)}
90
93
  />
91
94
  </div>
package/dist/index.esm.js CHANGED
@@ -178,14 +178,20 @@ const Button = ({ onClick, label, variant = 'outline', type = 'button', size = '
178
178
  };
179
179
 
180
180
  const errorClasses$2 = 'tw-border-sq-danger-color';
181
- const borderColorClasses$2 = ['tw-border-sq-disabled-gray', 'dark:tw-border-sq-dark-disabled-gray'].join(' ');
181
+ const borderColorClasses$2 = [
182
+ 'tw-border-sq-disabled-gray',
183
+ 'dark:tw-border-sq-dark-disabled-gray',
184
+ 'dark:focus:tw-border-sq-color-dark-dark',
185
+ 'dark:active:tw-border-sq-color-dark-dark',
186
+ 'focus:tw-border-sq-color-dark',
187
+ 'active:tw-border-sq-color-dark',
188
+ ].join(' ');
182
189
  const baseClasses$3 = 'tw-h-inputs tw-leading-normal tw-outline-none tw-py-1 tw-px-3' +
183
190
  ' disabled:tw-pointer-events-none' +
184
191
  ' disabled:tw-cursor-not-allowed tw-p-1 tw-border-solid tw-border tw-placeholder-gray-400' +
185
192
  ' dark:tw-placeholder-sq-dark-text-lighter specTextField';
186
- const darkTheme$1 = 'dark:tw-bg-sq-dark-background dark:tw-text-sq-dark-text' +
187
- ' dark:focus:tw-border-sq-color-dark-dark dark:active:tw-border-sq-color-dark-dark';
188
- const lightTheme$1 = 'tw-text-sq-text-color focus:tw-border-sq-color-dark active:tw-border-sq-color-dark';
193
+ const darkTheme$1 = 'dark:tw-bg-sq-dark-background dark:tw-text-sq-dark-text';
194
+ const lightTheme$1 = 'tw-text-sq-text-color';
189
195
  const sizeClasses = {
190
196
  sm: 'tw-text-sm',
191
197
  lg: 'tw-text-xl',
@@ -256,11 +262,17 @@ const Checkbox = (props) => {
256
262
 
257
263
  const baseClasses$1 = 'tw-leading-normal tw-outline-none tw-py-1 tw-px-3 tw-rounded-sm' +
258
264
  ' disabled:tw-cursor-not-allowed tw-p-1 tw-border-solid tw-border tw-text-sm';
259
- const darkTheme = 'dark:tw-bg-sq-dark-background dark:tw-text-sq-dark-text' +
260
- ' dark:focus:tw-border-sq-color-dark-dark dark:active:tw-border-sq-color-dark-dark dark:tw-placeholder-sq-dark-text-lighter';
261
- const lightTheme = 'tw-text-sq-text-color focus:tw-border-sq-color-dark active:tw-border-sq-color-dark tw-placeholder-gray-400';
265
+ const darkTheme = 'dark:tw-bg-sq-dark-background dark:tw-text-sq-dark-text ' + 'dark:tw-placeholder-sq-dark-text-lighter';
266
+ const lightTheme = 'tw-text-sq-text-color tw-placeholder-gray-400';
262
267
  const errorClasses$1 = 'tw-border-sq-danger-color';
263
- const borderColorClasses$1 = ['tw-border-sq-disabled-gray', 'dark:tw-border-sq-dark-disabled-gray'].join(' ');
268
+ const borderColorClasses$1 = [
269
+ 'tw-border-sq-disabled-gray',
270
+ 'dark:tw-border-sq-dark-disabled-gray',
271
+ 'dark:focus:tw-border-sq-color-dark-dark',
272
+ 'dark:active:tw-border-sq-color-dark-dark',
273
+ 'focus:tw-border-sq-color-dark',
274
+ 'active:tw-border-sq-color-dark',
275
+ ].join(' ');
264
276
  /**
265
277
  * TextArea.
266
278
  */