import type { Meta, StoryObj } from '@storybook/react-webpack5'; import { useRtlDiffI18n, withRTLDiff } from '../../../../.storybook/decorators/RtlDiffDecorator'; import { Size } from '../../../common'; import { SearchInput } from '../SearchInput'; import { WithOverlaidAbsoluteElement } from '../../../../.storybook/components/WithOverlaidAbsoluteElement'; export default { component: SearchInput, title: 'Forms/SearchInput/Tests', tags: ['!autodocs', '!manifest'], } satisfies Meta; type Story = StoryObj; export const RTLDiff: Story = { render: () => { const i18n = useRtlDiffI18n(); return ( <> {/* sm — search icon (addonStart) position flips to trailing side in RTL */} {/* md — search icon (addonStart) position flips to trailing side in RTL */} {/* sm rectangle — icon flip with rectangle shape */} {/* md rectangle — icon flip with rectangle shape */} ); }, ...withRTLDiff({ i18n: { placeholder: { en: 'Search', ar: 'بحث' }, }, }), }; export const StackingContext: Story = { render: () => ( ), };