Skip to content

Commit 8000605

Browse files
committed
fix(ActionDialog,Formdialog): スクロールできない問題を修正
1 parent f2f34f6 commit 8000605

File tree

2 files changed

+8
-8
lines changed

2 files changed

+8
-8
lines changed

packages/smarthr-ui/src/components/Dialog/ActionDialog/ActionDialogContentInner.tsx

+4-4
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,6 @@ import { type DecoratorsType } from '../../../hooks/useDecorators'
66
import { Button } from '../../Button'
77
import { Cluster, Stack } from '../../Layout'
88
import { ResponseMessage } from '../../ResponseMessage'
9-
import { Section } from '../../SectioningContent'
109
import { DialogBody, type Props as DialogBodyProps } from '../DialogBody'
1110
import { DialogHeader, type Props as DialogHeaderProps } from '../DialogHeader'
1211
import { dialogContentInner } from '../dialogInnerStyle'
@@ -99,8 +98,9 @@ export const ActionDialogContentInner: FC<ActionDialogContentInnerProps> = ({
9998
}, [])
10099

101100
return (
102-
// eslint-disable-next-line smarthr/a11y-heading-in-sectioning-content
103-
<Section className={styles.wrapper}>
101+
// スクロールできるようにするため、Stack[as="section"]を使用
102+
// eslint-disable-next-line smarthr/best-practice-for-layouts, smarthr/a11y-heading-in-sectioning-content
103+
<Stack as="section" gap={0} className={styles.wrapper}>
104104
<DialogHeader title={title} subtitle={subtitle} titleTag={titleTag} titleId={titleId} />
105105
<DialogBody contentPadding={contentPadding} contentBgColor={contentBgColor}>
106106
{children}
@@ -128,7 +128,7 @@ export const ActionDialogContentInner: FC<ActionDialogContentInnerProps> = ({
128128
</div>
129129
)}
130130
</Stack>
131-
</Section>
131+
</Stack>
132132
)
133133
}
134134

packages/smarthr-ui/src/components/Dialog/FormDialog/FormDialogContentInner.tsx

+4-4
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,6 @@ import { type DecoratorsType } from '../../../hooks/useDecorators'
1212
import { Button } from '../../Button'
1313
import { Cluster, Stack } from '../../Layout'
1414
import { ResponseMessage } from '../../ResponseMessage'
15-
import { Section } from '../../SectioningContent'
1615
import { DialogBody, Props as DialogBodyProps } from '../DialogBody'
1716
import { DialogHeader, type Props as DialogHeaderProps } from '../DialogHeader'
1817
import { dialogContentInner } from '../dialogInnerStyle'
@@ -124,8 +123,9 @@ export const FormDialogContentInner: FC<FormDialogContentInnerProps> = ({
124123
}, [])
125124

126125
return (
127-
// eslint-disable-next-line smarthr/a11y-prohibit-sectioning-content-in-form, smarthr/a11y-heading-in-sectioning-content
128-
<Section className={styles.wrapper}>
126+
// スクロールできるようにするため、Stack[as="section"]を使用
127+
// eslint-disable-next-line smarthr/best-practice-for-layouts, smarthr/a11y-heading-in-sectioning-content, smarthr/a11y-prohibit-sectioning-content-in-form
128+
<Stack as="section" gap={0} className={styles.wrapper}>
129129
<DialogHeader title={title} subtitle={subtitle} titleTag={titleTag} titleId={titleId} />
130130
<form onSubmit={handleSubmitAction} className={styles.form}>
131131
<DialogBody contentPadding={contentPadding} contentBgColor={contentBgColor}>
@@ -154,7 +154,7 @@ export const FormDialogContentInner: FC<FormDialogContentInnerProps> = ({
154154
)}
155155
</Stack>
156156
</form>
157-
</Section>
157+
</Stack>
158158
)
159159
}
160160

0 commit comments

Comments
 (0)