You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
you can customize jb-date-input look by setting css variable in your app.
296
+
jb-date-input use [jb-input](https://github.com/javadbat/jb-input) and [jb-calendar](https://github.com/javadbat/jb-calendar) and [jb-popover](https://github.com/javadbat/jb-popover) underneath so to change the styles of your component read custom style section of these components and set their css variable.
297
+
more than above here is the css variable that we use in jb-date-input itself:
298
+
293
299
#### variable list
294
300
295
301
| css variable name | description |
296
302
| ------------- | ------------- |
297
303
| --jb-date-input-margin | web-component margin default is `0 0`|
298
-
| --jb-date-input-border-radius | web-component border-radius default is `16px`|
299
-
| --jb-date-input-border-color | border color of select in normal mode |
300
-
| --jb-date-input-border-color-focus | border color when user focus on input |
301
-
| --jb-date-input-bgcolor | background color of input |
302
-
| --jb-date-input-message-box-display | default is block but if you set it to none message box will be hidden |
303
-
| --jb-date-input-message-box-color | change color of message under box |
304
-
| --jb-date-input-message-box-color-error | change color of message under box |
305
-
| --jb-date-input-message-box-font-size | font-size of message box under the input box |
306
-
| --jb-date-input-message-box-font-weight | font-weight of message box under the input box |
307
-
| --jb-date-input-message-box-padding | font-size of message box under the input box |
308
-
| --jb-date-input-text-align | text align of input |
309
-
| --jb-date-input-box-height | height of input box |
310
-
| --jb-date-input-border-width | general border width default is `1px`|
311
-
| --jb-date-input-border-bottom-width | border bottom width default is `3px`|
312
-
| --jb-date-input-label-font-size | font size of date input label default is `0.8em`|
313
-
| --jb-date-input-label-margin | change label margin default is `0 4px`|
314
-
| --jb-date-input-label-weight | label font-weight default is normal |
315
-
| --jb-date-input-placeholder-color | input placeholder color default is `initial`|
316
-
| --jb-date-input-placeholder-font-size | place holder font size default is `1.1em`|
317
-
| --jb-date-input-value-color | date input value color default is `#1f1735`|
318
-
| --jb-date-input-value-font-size | date input value font-size |
319
-
| --jb-date-input-calender-wrapper-bg-color | calender background color default color is `#fff`|
320
-
| --jb-date-input-calendar-wrapper-z-index | opend calendar `z-index` is `10` but you can change it to number you want |
321
-
| --jb-date-input-calender-wrapper-border-radius| calendar border radius default is `24px`|
322
-
| --jb-date-input-input-margin | input margin default is `4px 0`|
323
-
| --jb-date-input-box-shadow | input box-shadow default is none |
324
-
| --jb-date-input-box-shadow-focus | input box-shadow when input is focused default is none |
325
304
| --jb-date-input-calendar-trigger-display | set it no none to hide calendar icon |
305
+
| --jb-date-input-calendar-trigger-width | set calendar icon width |
306
+
| --jb-date-input-calendar-trigger-height | set calendar icon height |
326
307
327
-
328
-
if you want to change opened date picker style please read [jb-calendar](https://github.com/javadbat/jb-calendar) readme file
329
308
## add custom element in input box
330
309
331
310
in jb-input you can put icon or any other custom html DOM in input box. to doing so you just have to place custom DOM in `jb-date-input` tag and add `slot="start-section"` or `slot="end-section"` to place it before or after input field.
@@ -336,4 +315,12 @@ example:
336
315
<divslot="end-section">after</div>
337
316
<divslot="start-section">before</div>
338
317
</jb-date-input>
339
-
```
318
+
```
319
+
320
+
## Other Related Docs:
321
+
322
+
- see [jb-date-input-react](https://github.com/javadbat/jb-date-input-react) if you want to use this component in react
323
+
324
+
- see [All JB Design system Component List](https://github.com/javadbat/design-system/blob/master/docs/component-list.md) for more components
325
+
326
+
- use [Contribution Guide](https://github.com/javadbat/design-system/blob/master/docs/contribution-guide.md) if you want to contribute in this component.
* set opened calendar date when date input value is empty
1058
1060
* @public
1059
-
* @param{number} year which year you want to show in empty state in calendar.
1060
-
* @param{number} month which month you want to show in empty state in calendar.
1061
-
* @param{InputTypes} dateType default is your configured input-type but you can set it otherwise if you want to change other type of calendar in case of change in input-type.
1061
+
* @param year which year you want to show in empty state in calendar.
1062
+
* @param month which month you want to show in empty state in calendar.
1063
+
* @param dateType default is your configured input-type but you can set it otherwise if you want to change other type of calendar in case of change in input-type.
0 commit comments