Skip to content

Commit

Permalink
chore: added date and removed example code for Date Range Filter
Browse files Browse the repository at this point in the history
  • Loading branch information
tibuurcio committed Sep 25, 2024
1 parent 71b9118 commit 977140e
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 34 deletions.
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { Canvas, Meta } from '@storybook/blocks';
import { Meta, Story } from '@storybook/blocks';

import * as SelectWithRangePickerStories from './SelectWithRangePicker.stories';

Expand All @@ -22,11 +22,13 @@ The Date Range Filter consists of two main components:

The Date Range Filter can be used in dashboards, reports, or any interfaces where users interact with time-based data.

<Canvas of={SelectWithRangePickerStories.DateRangeFilter} />
<Story of={SelectWithRangePickerStories.DateRangeFilter} />

<br />

## Current usages

**Observability Project in CDP**
**9/25/2024 - Observability Project in CDP**

<ul>
<li>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -31,37 +31,6 @@ export const DateRangeFilter: Story = {
},
],
},
parameters: {
docs: {
source: {
code: `
<DateRangeFilter
onChange={(value, option) => {
console.log('onChange:', value, option);
}}
onSelect={(value, option) => {
console.log('onChange:', value, option);
}}
options={[
{
label: 'Last 24 hours',
value: 'last24hours'
},
{
label: 'Last 7 days',
value: 'last7days'
},
{
label: 'Last 30 days',
value: 'last30days'
}
]}
value="last30days"
/>
`,
},
},
},
render: function Render(args) {
const [{ value }, updateArgs] = useArgs()
return (
Expand Down
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
import React from 'react'
import { Select } from 'antd'
import { useMemo, useState } from 'react'
import { DateRangeString, type IDateRangeStringProps } from './DateRangeString'
Expand Down

0 comments on commit 977140e

Please sign in to comment.