Copybox input

Copybox input is a component that allows users to copy the content of an input field to the clipboard.

Examples Default
<dap-ds-copybox-input
label="Name"
placeholder="Enter your name">
</dap-ds-copybox-input>
States
<dap-ds-stack>
<dap-ds-copybox-input
  disabled
  label="Disabled"
  placeholder="Enter your name"
  value="John Doe">
</dap-ds-copybox-input>
<dap-ds-copybox-input
  readonly
  label="Readonly"
  placeholder="Enter your name"
  value="John Doe">
</dap-ds-copybox-input>
</dap-ds-stack>
Importing
import { DapDSCopyBoxInput } from 'dap-design-system/dist/dds'
Importing React
import { DapDSCopyBoxInputReact } from 'dap-design-system/dist/react'
Slots

No slots available.

Attributes
PropertyTypeDefaultDescription
labelstringThe label of the input.
placeholderstringThe placeholder of the input.
descriptionstringThe description of the input.
tooltipstringThe tooltip of the input.
status'success' 'error'The status of the input. Can be success or error.
size'sm' 'lg'The size of the input. Default is sm. Can be sm or lg.
namestringThe name of the input.
valuestring''The value of the input.
disabledbooleanThe disabled state of the input. Default is false.
requiredbooleanThe required state of the input. Default is false.
readonlybooleanThe readonly state of the input. Default is false.
autofocusbooleanThe autofocus state of the input. Default is false.
feedbackstringThe feedback of the input.
feedbackType'negative' 'positive' 'warning'The feedback type of the input. Can be negative, positive, or warning.
loadingbooleanThe loading state of the input. Default is false.
optionalbooleanThe optional state of the input.
optionalLabelstringThe optional label of the input.
subtlebooleanThe weight of the label. Default is false
Events
Event NameDescription
dds-copyFired when the user clicks on the copy button.
dds-changeFired when the input value changes.
dds-inputFired when the input value changes.
dds-keydownFired when a key is pressed down.
dds-blurFired when the input loses focus.
dds-focusEmitted when the input gains focus.
dds-not-allowedEmitted when the value cannot be copied.
CSS Parts
Part NameDescription
baseThe base container of the component.
postfixThe inner postfix icon part of the component.
buttonThe button of the component.