@cityway/basic-ui 1.0.2-beta008 → 1.0.2-beta010
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.
- package/cityway-basic-ui-1.0.2-beta010.tgz +0 -0
- package/fesm2022/cityway-basic-ui.mjs +33 -11
- package/fesm2022/cityway-basic-ui.mjs.map +1 -1
- package/index.d.ts +20 -6
- package/lib/assets/icons/sprite.preview.html +1 -1
- package/lib/assets/styles/scss/cw-ds/_reboot.scss +2 -2
- package/lib/assets/styles/scss/cw-ds/_root-fo.scss +4 -0
- package/lib/assets/styles/scss/cw-ds/components/_alert.scss +2 -0
- package/lib/assets/styles/scss/cw-ds/components/_dropdown.scss +34 -0
- package/lib/assets/styles/scss/cw-ds/components/_tooltip.scss +35 -0
- package/lib/assets/styles/scss/cw-ds/components/button/_button.scss +18 -13
- package/lib/assets/styles/scss/cw-ds/mixins/_popover-tooltip.scss +144 -0
- package/lib/assets/styles/scss/cw-ds/utilities/_flex.scss +20 -0
- package/lib/assets/styles/scss/cw-ds/utilities/_position.scss +24 -0
- package/lib/assets/styles/scss/styles-bo.scss +3 -0
- package/lib/assets/styles/scss/styles-fo.scss +3 -0
- package/package.json +1 -1
- package/styles/styles-bo.min.css +1 -1
- package/styles/styles-bo.min.css.map +1 -1
- package/styles/styles-fo.min.css +1 -1
- package/styles/styles-fo.min.css.map +1 -1
- package/cityway-basic-ui-1.0.2-beta008.tgz +0 -0
package/index.d.ts
CHANGED
|
@@ -2,6 +2,7 @@ import * as i0 from '@angular/core';
|
|
|
2
2
|
import { EventEmitter, OnInit, AfterViewInit, ElementRef, WritableSignal, ChangeDetectorRef, AfterContentInit, QueryList, TemplateRef, OnDestroy } from '@angular/core';
|
|
3
3
|
import { BehaviorSubject } from 'rxjs';
|
|
4
4
|
import { Options } from '@angular-slider/ngx-slider';
|
|
5
|
+
export { Options } from '@angular-slider/ngx-slider';
|
|
5
6
|
import { AbstractControl, FormGroup, FormControl, ValidationErrors } from '@angular/forms';
|
|
6
7
|
import { Router, ActivatedRoute } from '@angular/router';
|
|
7
8
|
import { TranslateService } from '@ngx-translate/core';
|
|
@@ -584,6 +585,7 @@ declare class AccordionComponent implements AfterContentInit {
|
|
|
584
585
|
}
|
|
585
586
|
|
|
586
587
|
declare enum AlertTypeEnum {
|
|
588
|
+
primary = "primary",
|
|
587
589
|
info = "info",
|
|
588
590
|
success = "success",
|
|
589
591
|
warning = "warning",
|
|
@@ -677,6 +679,7 @@ declare class ToastComponent {
|
|
|
677
679
|
}
|
|
678
680
|
|
|
679
681
|
declare enum BadgeTypeEnum {
|
|
682
|
+
lightPrimary = "light-primary",
|
|
680
683
|
lightInfo = "light-info",
|
|
681
684
|
lightSuccess = "light-success",
|
|
682
685
|
lightWarning = "light-warning",
|
|
@@ -715,7 +718,8 @@ declare class BadgeComponent {
|
|
|
715
718
|
declare enum FoButtonTypeEnum {
|
|
716
719
|
primary = "primary",
|
|
717
720
|
secondary = "secondary",
|
|
718
|
-
link = "link"
|
|
721
|
+
link = "link",
|
|
722
|
+
ghost = "ghost"
|
|
719
723
|
}
|
|
720
724
|
declare enum BoButtonTypeEnum {
|
|
721
725
|
primary = "primary",
|
|
@@ -726,7 +730,8 @@ declare enum BoButtonTypeEnum {
|
|
|
726
730
|
success = "success",
|
|
727
731
|
danger = "danger",
|
|
728
732
|
dangerOutline = "danger-outline",
|
|
729
|
-
light = "light"
|
|
733
|
+
light = "light",
|
|
734
|
+
ghost = "ghost"
|
|
730
735
|
}
|
|
731
736
|
declare enum ButtonIconSizeEnum {
|
|
732
737
|
default = "default",
|
|
@@ -737,6 +742,11 @@ declare enum ButtonPositionEnum {
|
|
|
737
742
|
left = "left",
|
|
738
743
|
right = "right"
|
|
739
744
|
}
|
|
745
|
+
declare enum DropdownPositionEnum {
|
|
746
|
+
left = "left",
|
|
747
|
+
right = "right",
|
|
748
|
+
static = "static"
|
|
749
|
+
}
|
|
740
750
|
declare enum TypeTooltipEnum {
|
|
741
751
|
tooltip = "tooltip",
|
|
742
752
|
popover = "popover"
|
|
@@ -772,7 +782,7 @@ declare class ButtonComponent implements OnInit {
|
|
|
772
782
|
withOnlyIcon?: boolean;
|
|
773
783
|
iconSize?: ButtonIconSizeEnum;
|
|
774
784
|
iconPosition?: ButtonPositionEnum;
|
|
775
|
-
dropdownPosition?:
|
|
785
|
+
dropdownPosition?: DropdownPositionEnum;
|
|
776
786
|
isMinWidth?: boolean;
|
|
777
787
|
isDisabled?: boolean;
|
|
778
788
|
isLoading?: boolean;
|
|
@@ -783,7 +793,7 @@ declare class ButtonComponent implements OnInit {
|
|
|
783
793
|
tooltipText?: string;
|
|
784
794
|
tooltipTitle?: string;
|
|
785
795
|
tooltipTrigger?: TriggerTooltipEnum;
|
|
786
|
-
tooltipPosition?:
|
|
796
|
+
tooltipPosition?: DropdownPositionEnum;
|
|
787
797
|
tooltipType?: TypeTooltipEnum;
|
|
788
798
|
btnAction: EventEmitter<string>;
|
|
789
799
|
dropDownClicked: EventEmitter<boolean>;
|
|
@@ -794,6 +804,7 @@ declare class ButtonComponent implements OnInit {
|
|
|
794
804
|
readonly iconType: typeof IconTypeEnum;
|
|
795
805
|
readonly iconUiType: typeof IconUiTypeEnum;
|
|
796
806
|
readonly buttonIconSizeEnum: typeof ButtonIconSizeEnum;
|
|
807
|
+
readonly spriteIcon: typeof SpriteIconEnum;
|
|
797
808
|
placementCss: string;
|
|
798
809
|
isOpen: boolean;
|
|
799
810
|
tooltipRandomId: number;
|
|
@@ -916,6 +927,7 @@ declare class FormFieldComponent implements OnInit {
|
|
|
916
927
|
skeletonMode?: boolean;
|
|
917
928
|
refreshEvent: EventEmitter<void>;
|
|
918
929
|
textChanged: EventEmitter<string>;
|
|
930
|
+
valueChange: EventEmitter<any>;
|
|
919
931
|
optionTemplate?: TemplateRef<any>;
|
|
920
932
|
labelTemplate?: TemplateRef<any>;
|
|
921
933
|
typeField: typeof FormFieldTypeEnum;
|
|
@@ -929,6 +941,7 @@ declare class FormFieldComponent implements OnInit {
|
|
|
929
941
|
get controlOrGroup(): AbstractControl<any, any, any>;
|
|
930
942
|
ngOnInit(): void;
|
|
931
943
|
onCheckboxChange(event: Event): void;
|
|
944
|
+
onRadioChange(value: any): void;
|
|
932
945
|
onBlur(): void;
|
|
933
946
|
isInInputGroup(): boolean;
|
|
934
947
|
getControl(path: 'start' | 'end'): FormControl | null;
|
|
@@ -943,7 +956,7 @@ declare class FormFieldComponent implements OnInit {
|
|
|
943
956
|
getRangePercent(): number;
|
|
944
957
|
onRangeStep(direction: 'increase' | 'decrease'): void;
|
|
945
958
|
static ɵfac: i0.ɵɵFactoryDeclaration<FormFieldComponent, never>;
|
|
946
|
-
static ɵcmp: i0.ɵɵComponentDeclaration<FormFieldComponent, "cw-form-field", never, { "control": { "alias": "control"; "required": false; }; "formGroup": { "alias": "formGroup"; "required": false; }; "type": { "alias": "type"; "required": false; }; "label": { "alias": "label"; "required": false; }; "displayLabel": { "alias": "displayLabel"; "required": false; }; "name": { "alias": "name"; "required": false; }; "placeholder": { "alias": "placeholder"; "required": false; }; "options": { "alias": "options"; "required": false; }; "rangeOptions": { "alias": "rangeOptions"; "required": false; }; "isRequired": { "alias": "isRequired"; "required": false; }; "help": { "alias": "help"; "required": false; }; "tooltip": { "alias": "tooltip"; "required": false; }; "addonLeft": { "alias": "addonLeft"; "required": false; }; "addonRight": { "alias": "addonRight"; "required": false; }; "isInAddon": { "alias": "isInAddon"; "required": false; }; "isReadonly": { "alias": "isReadonly"; "required": false; }; "isDisabled": { "alias": "isDisabled"; "required": false; }; "sliderValue": { "alias": "sliderValue"; "required": false; }; "sliderOptions": { "alias": "sliderOptions"; "required": false; }; "cssClass": { "alias": "cssClass"; "required": false; }; "skeletonMode": { "alias": "skeletonMode"; "required": false; }; }, { "refreshEvent": "refreshEvent"; "textChanged": "textChanged"; }, ["optionTemplate", "labelTemplate"], never, true, never>;
|
|
959
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<FormFieldComponent, "cw-form-field", never, { "control": { "alias": "control"; "required": false; }; "formGroup": { "alias": "formGroup"; "required": false; }; "type": { "alias": "type"; "required": false; }; "label": { "alias": "label"; "required": false; }; "displayLabel": { "alias": "displayLabel"; "required": false; }; "name": { "alias": "name"; "required": false; }; "placeholder": { "alias": "placeholder"; "required": false; }; "options": { "alias": "options"; "required": false; }; "rangeOptions": { "alias": "rangeOptions"; "required": false; }; "isRequired": { "alias": "isRequired"; "required": false; }; "help": { "alias": "help"; "required": false; }; "tooltip": { "alias": "tooltip"; "required": false; }; "addonLeft": { "alias": "addonLeft"; "required": false; }; "addonRight": { "alias": "addonRight"; "required": false; }; "isInAddon": { "alias": "isInAddon"; "required": false; }; "isReadonly": { "alias": "isReadonly"; "required": false; }; "isDisabled": { "alias": "isDisabled"; "required": false; }; "sliderValue": { "alias": "sliderValue"; "required": false; }; "sliderOptions": { "alias": "sliderOptions"; "required": false; }; "cssClass": { "alias": "cssClass"; "required": false; }; "skeletonMode": { "alias": "skeletonMode"; "required": false; }; }, { "refreshEvent": "refreshEvent"; "textChanged": "textChanged"; "valueChange": "valueChange"; }, ["optionTemplate", "labelTemplate"], never, true, never>;
|
|
947
960
|
}
|
|
948
961
|
|
|
949
962
|
declare class IconComponent {
|
|
@@ -1068,6 +1081,7 @@ declare class ModalsComponent implements OnInit, AfterViewInit {
|
|
|
1068
1081
|
danger: BoButtonTypeEnum.danger;
|
|
1069
1082
|
dangerOutline: BoButtonTypeEnum.dangerOutline;
|
|
1070
1083
|
light: BoButtonTypeEnum.light;
|
|
1084
|
+
ghost: BoButtonTypeEnum.ghost;
|
|
1071
1085
|
};
|
|
1072
1086
|
readonly spriteIcon: typeof SpriteIconEnum;
|
|
1073
1087
|
readonly iconType: typeof IconTypeEnum;
|
|
@@ -1334,5 +1348,5 @@ interface DataCustomListGroup {
|
|
|
1334
1348
|
fields: DataCustomList[];
|
|
1335
1349
|
}
|
|
1336
1350
|
|
|
1337
|
-
export { AccordionComponent, AlertComponent, AlertTypeEnum, BadgeComponent, BadgePositionEnum, BadgeTypeEnum, BoButtonTypeEnum, BoTabTypeEnum, ButtonComponent, ButtonIconSizeEnum, ButtonPositionEnum, CardComponent, CardTitleRankEnum, CardTypeEnum, ClickOutsideDirective, CollapseDirective, DropdownComponent, DropdownItemDirective, FileToDownloadComponent, FoButtonTypeEnum, FoTabTypeEnum, FocusTrackerService, FormFieldComponent, FormFieldTypeEnum, IconComponent, IconNotifSizeEnum, IconNotifTypeEnum, IconNotificationComponent, IconSizeEnum, IconTypeEnum, IconUiTypeEnum, ImageComponent, LegendComponent, LegendTypeEnum, LoaderComponent, ModalsComponent, ModalsService, ModalsSize, ModalsType, NumericalRangeComponent, NumericalRangeLabelPositionEnum, NumericalRangeTypeEnum, PlacementEnum, RequiredInfoComponent, ResponsiveService, SkipLinksComponent, SpriteIconEnum, StepperComponent, TabComponent, TabContentComponent, TitleComponent, TitleContextEnum, TitleTagEnum, ToastComponent, ToastService, TriggerTooltipEnum, TypeTooltipEnum, WizardStepComponent, WizardStepperComponent, rangeValidator };
|
|
1351
|
+
export { AccordionComponent, AlertComponent, AlertTypeEnum, BadgeComponent, BadgePositionEnum, BadgeTypeEnum, BoButtonTypeEnum, BoTabTypeEnum, ButtonComponent, ButtonIconSizeEnum, ButtonPositionEnum, CardComponent, CardTitleRankEnum, CardTypeEnum, ClickOutsideDirective, CollapseDirective, DropdownComponent, DropdownItemDirective, DropdownPositionEnum, FileToDownloadComponent, FoButtonTypeEnum, FoTabTypeEnum, FocusTrackerService, FormFieldComponent, FormFieldTypeEnum, IconComponent, IconNotifSizeEnum, IconNotifTypeEnum, IconNotificationComponent, IconSizeEnum, IconTypeEnum, IconUiTypeEnum, ImageComponent, LegendComponent, LegendTypeEnum, LoaderComponent, ModalsComponent, ModalsService, ModalsSize, ModalsType, NumericalRangeComponent, NumericalRangeLabelPositionEnum, NumericalRangeTypeEnum, PlacementEnum, RequiredInfoComponent, ResponsiveService, SkipLinksComponent, SpriteIconEnum, StepperComponent, TabComponent, TabContentComponent, TitleComponent, TitleContextEnum, TitleTagEnum, ToastComponent, ToastService, TriggerTooltipEnum, TypeTooltipEnum, WizardStepComponent, WizardStepperComponent, rangeValidator };
|
|
1338
1352
|
export type { Attachment, DataCustomList, DataCustomListGroup, DataLegend, FormFieldOption, FormFieldRangeOption, Legend, ModalRef, ShowToastOptions, SkipLink, Toast, ToastAction };
|
|
@@ -354,7 +354,7 @@ progress {
|
|
|
354
354
|
|
|
355
355
|
// HR
|
|
356
356
|
hr {
|
|
357
|
-
margin:
|
|
357
|
+
margin: 0;
|
|
358
358
|
color: inherit;
|
|
359
359
|
border: 0;
|
|
360
360
|
border-top: 1px solid currentColor;
|
|
@@ -363,7 +363,7 @@ hr {
|
|
|
363
363
|
|
|
364
364
|
// Blockquote
|
|
365
365
|
blockquote {
|
|
366
|
-
margin: 0
|
|
366
|
+
margin: 0;
|
|
367
367
|
padding-left: 1rem;
|
|
368
368
|
border-left: 0.25rem solid var(--border-color, #dee2e6);
|
|
369
369
|
}
|
|
@@ -5,6 +5,7 @@
|
|
|
5
5
|
.alert {
|
|
6
6
|
--#{p.$prefix}-alert-color: #{color(base, "black")};
|
|
7
7
|
--#{p.$prefix}-alert-bg-color: #{color(base, "white")};
|
|
8
|
+
--#{p.$prefix}-alert-border: 1px solid #{color(base, "white")};
|
|
8
9
|
|
|
9
10
|
display: flex;
|
|
10
11
|
align-items: center;
|
|
@@ -13,6 +14,7 @@
|
|
|
13
14
|
font-size: font(fs, xs);
|
|
14
15
|
line-height: font(lh, xs);
|
|
15
16
|
color: var(--#{p.$prefix}-alert-color);
|
|
17
|
+
border: var(--#{p.$prefix}-alert-border);
|
|
16
18
|
border-radius: var(--#{p.$prefix}-border-radius);
|
|
17
19
|
background-color: var(--#{p.$prefix}-alert-bg-color);
|
|
18
20
|
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
@use "sass:map";
|
|
2
|
+
@use "@cityway/design-tokens/primitives" as p;
|
|
3
|
+
@use "@cityway/design-tokens/functions" as *;
|
|
4
|
+
|
|
5
|
+
.dropdown {
|
|
6
|
+
position: relative;
|
|
7
|
+
|
|
8
|
+
&-menu {
|
|
9
|
+
position: absolute;
|
|
10
|
+
display: none;
|
|
11
|
+
|
|
12
|
+
&.show {
|
|
13
|
+
display: block;
|
|
14
|
+
}
|
|
15
|
+
|
|
16
|
+
&-static {
|
|
17
|
+
position: static;
|
|
18
|
+
}
|
|
19
|
+
|
|
20
|
+
&-right {
|
|
21
|
+
right: 0;
|
|
22
|
+
}
|
|
23
|
+
}
|
|
24
|
+
|
|
25
|
+
&-icon {
|
|
26
|
+
transition: rotate 200ms ease-in-out;
|
|
27
|
+
}
|
|
28
|
+
}
|
|
29
|
+
|
|
30
|
+
.btn[aria-expanded="true"] {
|
|
31
|
+
.dropdown-icon {
|
|
32
|
+
rotate: 180deg;
|
|
33
|
+
}
|
|
34
|
+
}
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
@use "sass:map";
|
|
2
|
+
@use "@cityway/design-tokens/primitives" as p;
|
|
3
|
+
@use "@cityway/design-tokens/functions" as *;
|
|
4
|
+
@use "../mixins/popover-tooltip" as m;
|
|
5
|
+
|
|
6
|
+
|
|
7
|
+
@include m.popover-base(
|
|
8
|
+
$name: "popover",
|
|
9
|
+
$width: 12.5rem,
|
|
10
|
+
$br: border(br, md),
|
|
11
|
+
$bg: var(--#{p.$prefix}-base-white),
|
|
12
|
+
$header-bg: #{color("grey", 100)},
|
|
13
|
+
$fs: font(fs, xs),
|
|
14
|
+
$lh: font(lh, xs),
|
|
15
|
+
$shadow: var(--#{p.$prefix}-shadow-default),
|
|
16
|
+
$arrow-size: 1rem,
|
|
17
|
+
$arrow-offset: 1.5rem,
|
|
18
|
+
$arrow-border-size: 0
|
|
19
|
+
);
|
|
20
|
+
|
|
21
|
+
@include m.popover-base(
|
|
22
|
+
$name: "tooltip",
|
|
23
|
+
$width: 10rem,
|
|
24
|
+
$br: border(br, sm),
|
|
25
|
+
$bg: var(--#{p.$prefix}-base-black),
|
|
26
|
+
$header-bg: transparent,
|
|
27
|
+
$fs: font(fs, xs),
|
|
28
|
+
$lh: font(lh, xs),
|
|
29
|
+
$shadow: var(--#{p.$prefix}-shadow-default),
|
|
30
|
+
$arrow-size: 0.625rem,
|
|
31
|
+
$arrow-offset: 1.125rem,
|
|
32
|
+
$arrow-border-size: 0
|
|
33
|
+
) {
|
|
34
|
+
color: var(--#{p.$prefix}-base-white);
|
|
35
|
+
};
|
|
@@ -7,24 +7,24 @@
|
|
|
7
7
|
--#{p.$prefix}-btn-padding-y: #{size(sm)};
|
|
8
8
|
--#{p.$prefix}-btn-min-width: 17rem;
|
|
9
9
|
|
|
10
|
-
--#{p.$prefix}-btn-bg:
|
|
11
|
-
--#{p.$prefix}-btn-color:
|
|
10
|
+
--#{p.$prefix}-btn-bg: transparent;
|
|
11
|
+
--#{p.$prefix}-btn-color: var(--#{p.$prefix}-body-color);
|
|
12
12
|
|
|
13
|
-
--#{p.$prefix}-btn-fs:
|
|
14
|
-
--#{p.$prefix}-btn-lh:
|
|
15
|
-
--#{p.$prefix}-btn-fw:
|
|
13
|
+
--#{p.$prefix}-btn-fs: var(--#{p.$prefix}-body-fs);
|
|
14
|
+
--#{p.$prefix}-btn-lh: var(--#{p.$prefix}-body-lh);;
|
|
15
|
+
--#{p.$prefix}-btn-fw: var(--#{p.$prefix}-body-fw);
|
|
16
16
|
|
|
17
|
-
--#{p.$prefix}-btn-border-color:
|
|
18
|
-
--#{p.$prefix}-btn-border-width:
|
|
17
|
+
--#{p.$prefix}-btn-border-color: transparent;
|
|
18
|
+
--#{p.$prefix}-btn-border-width: 0;
|
|
19
19
|
--#{p.$prefix}-btn-br: var(--#{p.$prefix}-border-radius-input);
|
|
20
20
|
|
|
21
|
-
--#{p.$prefix}-btn-hover-color:
|
|
22
|
-
--#{p.$prefix}-btn-hover-bg:
|
|
23
|
-
--#{p.$prefix}-btn-hover-border-color:
|
|
21
|
+
--#{p.$prefix}-btn-hover-color: var(--#{p.$prefix}-primary-hover);
|
|
22
|
+
--#{p.$prefix}-btn-hover-bg: transparent;
|
|
23
|
+
--#{p.$prefix}-btn-hover-border-color: var(--#{p.$prefix}-base-white);
|
|
24
24
|
|
|
25
|
-
--#{p.$prefix}-btn-disabled-color:
|
|
26
|
-
--#{p.$prefix}-btn-disabled-bg:
|
|
27
|
-
--#{p.$prefix}-btn-disabled-border-color:
|
|
25
|
+
--#{p.$prefix}-btn-disabled-color: var(--#{p.$prefix}-base-white);
|
|
26
|
+
--#{p.$prefix}-btn-disabled-bg: var(--#{p.$prefix}-base-disabled);
|
|
27
|
+
--#{p.$prefix}-btn-disabled-border-color: var(--#{p.$prefix}-base-disabled);
|
|
28
28
|
|
|
29
29
|
display: inline-flex;
|
|
30
30
|
align-items: center;
|
|
@@ -83,6 +83,11 @@
|
|
|
83
83
|
}
|
|
84
84
|
}
|
|
85
85
|
|
|
86
|
+
.btn-ghost {
|
|
87
|
+
padding: 0;
|
|
88
|
+
justify-content: start;
|
|
89
|
+
}
|
|
90
|
+
|
|
86
91
|
|
|
87
92
|
// MIXIN - Variantes
|
|
88
93
|
// ---------------------------------
|
|
@@ -0,0 +1,144 @@
|
|
|
1
|
+
@use "sass:map";
|
|
2
|
+
@use "@cityway/design-tokens/primitives" as p;
|
|
3
|
+
@use "@cityway/design-tokens/functions" as *;
|
|
4
|
+
|
|
5
|
+
// MIXIN arrow
|
|
6
|
+
// ---------------------------------
|
|
7
|
+
@mixin arrow($direction, $bg-color, $arrow-size, $arrow-offset, $arrow-border-size) {
|
|
8
|
+
$is-right: $direction ==right;
|
|
9
|
+
|
|
10
|
+
// position horizontale
|
|
11
|
+
@if $is-right {
|
|
12
|
+
left: -$arrow-size;
|
|
13
|
+
|
|
14
|
+
&::before {
|
|
15
|
+
left: -1px;
|
|
16
|
+
}
|
|
17
|
+
}
|
|
18
|
+
|
|
19
|
+
@else {
|
|
20
|
+
right: -$arrow-size;
|
|
21
|
+
|
|
22
|
+
&::before {
|
|
23
|
+
right: -1px;
|
|
24
|
+
}
|
|
25
|
+
}
|
|
26
|
+
|
|
27
|
+
// bordure (before)
|
|
28
|
+
&::before {
|
|
29
|
+
border-top: $arrow-border-size solid transparent;
|
|
30
|
+
border-bottom: $arrow-border-size solid transparent;
|
|
31
|
+
|
|
32
|
+
@if $is-right {
|
|
33
|
+
border-right: $arrow-border-size solid $bg-color;
|
|
34
|
+
}
|
|
35
|
+
|
|
36
|
+
@else {
|
|
37
|
+
border-left: $arrow-border-size solid $bg-color;
|
|
38
|
+
}
|
|
39
|
+
}
|
|
40
|
+
|
|
41
|
+
// fond (after)
|
|
42
|
+
&::after {
|
|
43
|
+
border-top: $arrow-size solid transparent;
|
|
44
|
+
border-bottom: $arrow-size solid transparent;
|
|
45
|
+
|
|
46
|
+
@if $is-right {
|
|
47
|
+
border-right: $arrow-size solid $bg-color;
|
|
48
|
+
}
|
|
49
|
+
|
|
50
|
+
@else {
|
|
51
|
+
border-left: $arrow-size solid $bg-color;
|
|
52
|
+
}
|
|
53
|
+
}
|
|
54
|
+
}
|
|
55
|
+
|
|
56
|
+
// MIXIN BASE POPOVER/TOOLTIP
|
|
57
|
+
// ---------------------------------
|
|
58
|
+
@mixin popover-base($name,
|
|
59
|
+
$width,
|
|
60
|
+
$br,
|
|
61
|
+
$bg,
|
|
62
|
+
$header-bg,
|
|
63
|
+
$fs,
|
|
64
|
+
$lh,
|
|
65
|
+
$shadow,
|
|
66
|
+
$arrow-size,
|
|
67
|
+
$arrow-offset,
|
|
68
|
+
$arrow-border-size
|
|
69
|
+
) {
|
|
70
|
+
.#{$name} {
|
|
71
|
+
--#{p.$prefix}-#{$name}-br: #{$br};
|
|
72
|
+
--#{p.$prefix}-#{$name}-bg: #{$bg};
|
|
73
|
+
--#{p.$prefix}-#{$name}-header-bg: #{$header-bg};
|
|
74
|
+
|
|
75
|
+
position: absolute;
|
|
76
|
+
top: 50%;
|
|
77
|
+
transform: translateY(-50%);
|
|
78
|
+
min-width: $width;
|
|
79
|
+
max-width: $width;
|
|
80
|
+
border-radius: var(--#{p.$prefix}-#{$name}-br);
|
|
81
|
+
background-color: var(--#{p.$prefix}-#{$name}-bg);
|
|
82
|
+
box-shadow: #{$shadow};
|
|
83
|
+
|
|
84
|
+
// slot pour les overrides spécifiques
|
|
85
|
+
@content;
|
|
86
|
+
|
|
87
|
+
.arrow {
|
|
88
|
+
position: absolute;
|
|
89
|
+
top: 50%;
|
|
90
|
+
transform: translateY(-50%);
|
|
91
|
+
width: 0;
|
|
92
|
+
height: 0;
|
|
93
|
+
|
|
94
|
+
&::before,
|
|
95
|
+
&::after {
|
|
96
|
+
content: "";
|
|
97
|
+
position: absolute;
|
|
98
|
+
top: 50%;
|
|
99
|
+
transform: translateY(-50%);
|
|
100
|
+
width: 0;
|
|
101
|
+
height: 0;
|
|
102
|
+
}
|
|
103
|
+
|
|
104
|
+
&::after {
|
|
105
|
+
filter: drop-shadow(var(--#{p.$prefix}-shadow-filter));
|
|
106
|
+
}
|
|
107
|
+
}
|
|
108
|
+
|
|
109
|
+
&-right {
|
|
110
|
+
left: 100%;
|
|
111
|
+
margin-left: 1.5rem;
|
|
112
|
+
|
|
113
|
+
.arrow {
|
|
114
|
+
@include arrow(right, var(--#{p.$prefix}-#{$name}-bg), $arrow-size, $arrow-offset, $arrow-border-size);
|
|
115
|
+
}
|
|
116
|
+
}
|
|
117
|
+
|
|
118
|
+
&-left {
|
|
119
|
+
right: 100%;
|
|
120
|
+
margin-right: 1.5rem;
|
|
121
|
+
|
|
122
|
+
.arrow {
|
|
123
|
+
@include arrow(left, var(--#{p.$prefix}-#{$name}-bg), $arrow-size, $arrow-offset, $arrow-border-size);
|
|
124
|
+
}
|
|
125
|
+
}
|
|
126
|
+
|
|
127
|
+
&-header,
|
|
128
|
+
&-body {
|
|
129
|
+
padding: size(2xs) size(sm);
|
|
130
|
+
font-size: $fs;
|
|
131
|
+
line-height: $lh;
|
|
132
|
+
}
|
|
133
|
+
|
|
134
|
+
&-body {
|
|
135
|
+
border-radius: var(--#{p.$prefix}-#{$name}-br);
|
|
136
|
+
}
|
|
137
|
+
|
|
138
|
+
&-header {
|
|
139
|
+
font-weight: font(fw, bold);
|
|
140
|
+
border-radius: var(--#{p.$prefix}-#{$name}-br) var(--#{p.$prefix}-#{$name}-br) 0 0;
|
|
141
|
+
background-color: var(--#{p.$prefix}-#{$name}-header-bg);
|
|
142
|
+
}
|
|
143
|
+
}
|
|
144
|
+
}
|
|
@@ -2,6 +2,18 @@
|
|
|
2
2
|
|
|
3
3
|
@include generate-flex-system();
|
|
4
4
|
|
|
5
|
+
.d-block {
|
|
6
|
+
display: block;
|
|
7
|
+
}
|
|
8
|
+
|
|
9
|
+
.d-none {
|
|
10
|
+
display: none;
|
|
11
|
+
}
|
|
12
|
+
|
|
13
|
+
.d-inline-block {
|
|
14
|
+
display: inline-block;
|
|
15
|
+
}
|
|
16
|
+
|
|
5
17
|
.d-flex-h,
|
|
6
18
|
.d-flex-v {
|
|
7
19
|
display: flex;
|
|
@@ -98,3 +110,11 @@
|
|
|
98
110
|
.flex-none {
|
|
99
111
|
flex: none;
|
|
100
112
|
}
|
|
113
|
+
|
|
114
|
+
.flex-grow-1 {
|
|
115
|
+
flex-grow: 1;
|
|
116
|
+
}
|
|
117
|
+
|
|
118
|
+
.flex-shrink-0 {
|
|
119
|
+
flex-shrink: 0;
|
|
120
|
+
}
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
|
|
2
|
+
// MIXIN - Variantes
|
|
3
|
+
// ---------------------------------
|
|
4
|
+
@mixin generate-position-utilities($map, $prefix: 'p') {
|
|
5
|
+
@each $name, $value in $map {
|
|
6
|
+
.#{$prefix}-#{$name} {
|
|
7
|
+
position: $value;
|
|
8
|
+
}
|
|
9
|
+
}
|
|
10
|
+
}
|
|
11
|
+
|
|
12
|
+
// Variables
|
|
13
|
+
// ---------------------------------
|
|
14
|
+
$positions: (
|
|
15
|
+
relative: relative,
|
|
16
|
+
absolute: absolute,
|
|
17
|
+
fixed: fixed,
|
|
18
|
+
sticky: sticky
|
|
19
|
+
);
|
|
20
|
+
|
|
21
|
+
|
|
22
|
+
// Générer toutes les variantes
|
|
23
|
+
// ---------------------------------
|
|
24
|
+
@include generate-position-utilities($positions);
|
|
@@ -27,6 +27,8 @@
|
|
|
27
27
|
@use "cw-ds/components/numerical-range";
|
|
28
28
|
@use "cw-ds/components/modal";
|
|
29
29
|
@use "cw-ds/components/form-field/form-field";
|
|
30
|
+
@use "cw-ds/components/tooltip";
|
|
31
|
+
@use "cw-ds/components/dropdown";
|
|
30
32
|
|
|
31
33
|
// Utilities
|
|
32
34
|
@use "cw-ds/utilities/breakpoints";
|
|
@@ -36,6 +38,7 @@
|
|
|
36
38
|
@use "cw-ds/utilities/type/type";
|
|
37
39
|
@use "cw-ds/utilities/type/type-bo";
|
|
38
40
|
@use "cw-ds/utilities/alignment";
|
|
41
|
+
@use "cw-ds/utilities/position";
|
|
39
42
|
|
|
40
43
|
// En surcharge
|
|
41
44
|
@use "cw-ds/helpers/skeleton";
|
|
@@ -27,6 +27,8 @@
|
|
|
27
27
|
@use "cw-ds/components/numerical-range";
|
|
28
28
|
@use "cw-ds/components/modal";
|
|
29
29
|
@use "cw-ds/components/form-field/form-field";
|
|
30
|
+
@use "cw-ds/components/tooltip";
|
|
31
|
+
@use "cw-ds/components/dropdown";
|
|
30
32
|
|
|
31
33
|
// Utilities
|
|
32
34
|
@use "cw-ds/utilities/breakpoints";
|
|
@@ -36,6 +38,7 @@
|
|
|
36
38
|
@use "cw-ds/utilities/type/type";
|
|
37
39
|
@use "cw-ds/utilities/type/type-fo";
|
|
38
40
|
@use "cw-ds/utilities/alignment";
|
|
41
|
+
@use "cw-ds/utilities/position";
|
|
39
42
|
|
|
40
43
|
// En surcharge
|
|
41
44
|
@use "cw-ds/helpers/skeleton";
|