Merge remote-tracking branch 'parent/main' into upstream-20240319

This commit is contained in:
KMY 2024-03-19 09:15:20 +09:00
commit 76598bd542
496 changed files with 5795 additions and 3709 deletions

View file

@ -68,12 +68,19 @@
.fields-group.fields-row__column.fields-row__column-6
.input.select.optional
.label_input
= f.select :category_id, options_from_collection_for_select(CustomEmojiCategory.all, 'id', 'name'), prompt: t('admin.custom_emojis.assign_category'), class: 'select optional', 'aria-label': t('admin.custom_emojis.assign_category')
= f.select :category_id,
options_from_collection_for_select(CustomEmojiCategory.all, 'id', 'name'),
'aria-label': t('admin.custom_emojis.assign_category'),
class: 'select optional',
prompt: t('admin.custom_emojis.assign_category')
.fields-group.fields-row__column.fields-row__column-6
.input.string.optional
.label_input
= f.text_field :category_name, class: 'string optional', placeholder: t('admin.custom_emojis.create_new_category'), 'aria-label': t('admin.custom_emojis.create_new_category')
= f.text_field :category_name,
'aria-label': t('admin.custom_emojis.create_new_category'),
class: 'string optional',
placeholder: t('admin.custom_emojis.create_new_category')
.batch-table__body
- if @custom_emojis.empty?

View file

@ -5,10 +5,16 @@
= render 'shared/error_messages', object: @custom_emoji
.fields-group
= f.input :shortcode, wrapper: :with_label, label: t('admin.custom_emojis.shortcode'), hint: t('admin.custom_emojis.shortcode_hint')
= f.input :shortcode,
wrapper: :with_label,
label: t('admin.custom_emojis.shortcode'),
hint: t('admin.custom_emojis.shortcode_hint')
.fields-group
= f.input :image, wrapper: :with_label, input_html: { accept: CustomEmoji::IMAGE_MIME_TYPES.join(',') }, hint: t('admin.custom_emojis.image_hint', size: number_to_human_size(CustomEmoji::LIMIT))
= f.input :image,
wrapper: :with_label,
input_html: { accept: CustomEmoji::IMAGE_MIME_TYPES.join(',') },
hint: t('admin.custom_emojis.image_hint', size: number_to_human_size(CustomEmoji::LIMIT))
.fields-group
= f.input :category_id, collection: CustomEmojiCategory.all, label_method: ->(item) { item.name }, collection_wrapper_tag: 'ul', item_wrapper_tag: 'li', include_blank: t('admin.custom_emojis.assign_category'), wrapper: :with_label, label: false, hint: false
@ -23,4 +29,6 @@
= f.input :license, wrapper: :with_label, kmyblue: true, label: t('admin.custom_emojis.license'), hint: t('admin.custom_emojis.license_hint')
.actions
= f.button :button, t('admin.custom_emojis.upload'), type: :submit
= f.button :button,
t('admin.custom_emojis.upload'),
type: :submit