extendLabel.ts 383 B

1234567891011121314
  1. // Copyright (C) 2012-2024 Zammad Foundation, https://zammad-foundation.org/
  2. import type { FormKitNode } from '@formkit/core'
  3. import extendSchemaDefinition from '#shared/form/utils/extendSchemaDefinition.ts'
  4. const extendLabel = (node: FormKitNode) => {
  5. extendSchemaDefinition(node, 'label', {
  6. attrs: {
  7. id: '$: "label-" + $id',
  8. },
  9. })
  10. }
  11. export default extendLabel