Skip to content

Commit

Permalink
Merge pull request #354 from ironSource/fix/isct-430-component-v4-fixes
Browse files Browse the repository at this point in the history
Components v4 fixed/changes from studio
  • Loading branch information
AndyKIron authored Dec 12, 2024
2 parents 7a2c177 + 18a41a3 commit dacd5b0
Show file tree
Hide file tree
Showing 6 changed files with 52 additions and 11 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -110,10 +110,12 @@
span {
position: relative;
}

&:empty{
cursor: default;
}

// region regular day hover
&:not(.selected):not(.disabled):not(.hover-current):hover {
&:not(.selected):not(.disabled):not(.hover-current):not(:empty):hover {
&:before {
@include calendar-circle(var(--fu-day-hover-bg-color), 50%);
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -72,6 +72,22 @@ const baseTemplateMultiselect = `
</fusion-chip-filter-button>
`;

const datePeriodTemplate = `
<fusion-chip-filter-button [showCaretIcon]="showCaretIcon" [size]="size" [weight]="weight" [configuration]="configuration">
<div class="filter-element">
<fusion-dropdown style="--dropdown-overlay-min-width: 250px"
[placeholderPrefix]="placeholderPrefix"
[placeholder]="placeholder"
[formControl]="formControl"
[options]="options"
[optionsTitle]="optionsTitle"
[search]="search"
>
</fusion-dropdown>
</div>
</fusion-chip-filter-button>
`;

export default {
title: 'V4/Components/Dropdown/Triggers/ButtonFilter',
component: ChipFilterButtonComponent,
Expand Down Expand Up @@ -380,7 +396,7 @@ export const DatePeriodPicker: Story = {
formControl: new FormControl([MOCK_OPTIONS_PERIOD[1]]),
configuration: {id: 1, mode: 'static', close: true, leftIcon: {icon: 'ph/calendar-blank'}}
},
template: baseTemplate
template: datePeriodTemplate
}),
decorators: [componentWrapperDecorator(story => `<div style="height: 200px;">${story}</div>`)]
};
Original file line number Diff line number Diff line change
Expand Up @@ -112,7 +112,7 @@ new FormControl({
}
};

export const SelectedToday: Story = {
export const Today: Story = {
render: args => ({
props: {
...args,
Expand All @@ -124,7 +124,7 @@ export const SelectedToday: Story = {
template: BASE_TEMPLATE
})
};
SelectedToday.parameters = {
Today.parameters = {
docs: {
description: {
story: dedent`***formControl:***
Expand All @@ -138,7 +138,7 @@ new FormControl({
}
};

export const SelectedLast14Days: Story = {
export const Last14Days: Story = {
render: args => ({
props: {
...args,
Expand All @@ -150,6 +150,7 @@ export const SelectedLast14Days: Story = {
template: BASE_TEMPLATE
})
};
Last14Days.storyName = 'Last 14 days';

export const WithoutPresets: Story = {
render: args => ({
Expand All @@ -167,6 +168,7 @@ WithoutPresets.parameters = {
}
}
};
WithoutPresets.storyName = 'Without presets';

export const LimitedRange: Story = {
render: args => ({
Expand All @@ -190,6 +192,7 @@ LimitedRange.parameters = {
}
}
};
LimitedRange.storyName = 'Limited range';

export const NotAllowFutureDateSelected: Story = {
render: args => ({
Expand All @@ -207,6 +210,7 @@ NotAllowFutureDateSelected.parameters = {
}
}
};
NotAllowFutureDateSelected.storyName = 'Not future date';

export const WithTimeSelect: Story = {
render: args => ({
Expand Down Expand Up @@ -245,3 +249,4 @@ WithTimeSelect.parameters = {
}
}
};
WithTimeSelect.storyName = 'Selected time';
Loading

0 comments on commit dacd5b0

Please sign in to comment.