mirror of
https://github.com/chillpadclub/bedolaga-cabinet.git
synced 2026-07-28 17:43:47 +00:00
fix(a11y): label associations for AdminPromoGroupCreate + AdminPinnedMessageCreate
Add htmlFor/id pairs for the name + auto-assign inputs (AdminPromoGroupCreate) and the content textarea (AdminPinnedMessageCreate). AdminPromoOfferSend skipped — its labels sit above button-groups, not native controls (a separate role=group/radiogroup pass).
This commit is contained in:
@@ -246,10 +246,11 @@ export default function AdminPinnedMessageCreate() {
|
||||
<div className="card space-y-6">
|
||||
{/* Message text */}
|
||||
<div>
|
||||
<label className="mb-2 block text-sm font-medium text-dark-300">
|
||||
<label htmlFor="pm-content" className="mb-2 block text-sm font-medium text-dark-300">
|
||||
{t('admin.pinnedMessages.content')}
|
||||
</label>
|
||||
<textarea
|
||||
id="pm-content"
|
||||
value={content}
|
||||
onChange={(e) => setContent(e.target.value)}
|
||||
placeholder={t('admin.pinnedMessages.contentPlaceholder')}
|
||||
|
||||
@@ -192,11 +192,12 @@ export default function AdminPromoGroupCreate() {
|
||||
<div className="card space-y-4">
|
||||
{/* Name */}
|
||||
<div>
|
||||
<label className="mb-2 block text-sm font-medium text-dark-300">
|
||||
<label htmlFor="pg-name" className="mb-2 block text-sm font-medium text-dark-300">
|
||||
{t('admin.promoGroups.form.name')}
|
||||
<span className="text-error-400">*</span>
|
||||
</label>
|
||||
<input
|
||||
id="pg-name"
|
||||
type="text"
|
||||
value={name}
|
||||
onChange={(e) => setName(e.target.value)}
|
||||
@@ -349,11 +350,12 @@ export default function AdminPromoGroupCreate() {
|
||||
|
||||
{/* Auto-assign */}
|
||||
<div>
|
||||
<label className="mb-2 block text-sm font-medium text-dark-300">
|
||||
<label htmlFor="pg-auto-assign" className="mb-2 block text-sm font-medium text-dark-300">
|
||||
{t('admin.promoGroups.form.autoAssign')}
|
||||
</label>
|
||||
<div className="flex items-center gap-2">
|
||||
<input
|
||||
id="pg-auto-assign"
|
||||
type="number"
|
||||
value={autoAssignSpent}
|
||||
onChange={(e) => {
|
||||
|
||||
Reference in New Issue
Block a user