Skip to content
Accessibility: Full
Translations: Not Needed

Input Text (Inline)

Minimalist input that appears as text until focused, perfect for in-place editing.

Required Prop

Set inline to true to enable inline mode.

Basic Usage

Click to edit...

With prefix icon...

With suffix icon and tooltip...

Disabled inline input...

vue
<template>
  <!-- Basic inline input -->
  <HLInput v-model:modelValue="value" inline placeholder="Click to edit..." :showInlineBottomBorder="false" />

  <!-- With prefix icon -->
  <HLInput v-model:modelValue="value" inline :prefix-icon="Mail01Icon" placeholder="With prefix icon..." :showInlineBottomBorder="false" />

  <!-- With suffix icon and tooltip -->
  <HLInput
    v-model:modelValue="value"
    inline
    :suffix-icon="HelpCircleIcon"
    suffix-icon-tooltip-content="This is a help tooltip"
    placeholder="With suffix icon and tooltip..."
    :showInlineBottomBorder="false"
  />

  <!-- Disabled state -->
  <HLInput v-model:modelValue="value" inline disabled placeholder="Disabled inline input..." :showInlineBottomBorder="false" />
</template>

<script setup>
import { ref } from 'vue'
import { HLInput } from '@platform-ui/highrise'
import { Mail01Icon, HelpCircleIcon } from '@gohighlevel/ghl-icons/24/outline'

const value = ref('')
</script>

Inline Editing with CTA Buttons

Inline input with confirm and cancel actions for explicit user control.

Click to edit with confirm/cancel...

With bottom border...

With prefix icon...

vue
<template>
  <!-- Basic inline input with confirm/cancel CTAs -->
  <HLInput
    v-model:modelValue="value"
    inline
    showInlineCTA
    placeholder="Click to edit with confirm/cancel..."
    :showInlineBottomBorder="false"
  />

  <!-- With bottom border -->
  <HLInput v-model:modelValue="value" inline showInlineCTA placeholder="With bottom border..." />

  <!-- With prefix icon -->
  <HLInput
    v-model:modelValue="value"
    inline
    showInlineCTA
    :prefix-icon="Mail01Icon"
    placeholder="With prefix icon..."
    :showInlineBottomBorder="false"
  />
</template>

<script setup>
import { ref } from 'vue'
import { HLInput } from '@platform-ui/highrise'
import { Mail01Icon } from '@gohighlevel/ghl-icons/24/outline'

const value = ref('')
</script>

Inline Input with Form Validation

Inline input integrated with form validation and error states.

Enter username...

vue
<template>
  <HLFormItem label="Username" required validation-status="error">
    <HLInput v-model:modelValue="value" placeholder="Enter username..." inline />
  </HLFormItem>
</template>

<script setup>
import { ref } from 'vue'
import { HLInput, HLFormItem } from '@platform-ui/highrise'

const value = ref('')
</script>

Inline Input with Edit Actions and Saved Icon

Inline input with custom edit actions and animated saved confirmation icon.

Enter your message with icons...

vue
<template>
  <HLInput
    ref="inputRef"
    v-model:modelValue="value"
    inline
    showInlineCTA
    placeholder="Enter your message with icons..."
    :showInlineBottomBorder="false"
    @confirm="handleConfirm"
    @cancel="handleCancel"
  >
    <template #suffix>
      <HLIcon :size="18" color="var(--gray-400)">
        <MessageDotsCircleIcon />
      </HLIcon>
    </template>
    <template #edit-actions>
      <HLIcon :size="18" color="var(--gray-600)" @click="handleEditClick">
        <Edit02Icon />
      </HLIcon>
      <HLIcon :size="18" color="var(--success-600)" @click="handlePhoneClick">
        <PhoneIcon />
      </HLIcon>
      <HLIcon :size="18" color="var(--gray-600)" @click="handleMailClick">
        <Mail01Icon />
      </HLIcon>
    </template>
  </HLInput>
</template>

<script setup>
import { ref } from 'vue'
import { HLInput, HLIcon } from '@platform-ui/highrise'
import { Edit02Icon, PhoneIcon, Mail01Icon, MessageDotsCircleIcon } from '@gohighlevel/ghl-icons/24/outline'

const value = ref('')
const inputRef = ref(null)

const handleConfirm = () => {
  // Trigger saved icon using the exposed method
  inputRef.value?.triggerSavedIcon()
  // Clear saved icon after 2 seconds
  setTimeout(() => {
    inputRef.value?.clearSavedIcon()
  }, 2000)
}

const handleCancel = () => {
  // Value is automatically restored by the component
  console.log('Input cancelled, value restored')
}

const handleEditClick = () => {
  console.log('Edit action clicked')
}

const handlePhoneClick = () => {
  console.log('Phone action clicked')
}

const handleMailClick = () => {
  console.log('Mail action clicked')
}
</script>

Accessibility

  • Connect the field to visible labels via id / for or supply aria-label when the label is hidden.
  • Reference helper and error copy through aria-describedby, and toggle aria-invalid when validation fails.
  • Manage suggestion lists with aria-expanded, aria-controls, and (when applicable) aria-autocomplete so assistive tech understands the relationship.
  • Use inputProps prop to pass attributes to the internal <input> element.

Imports

ts
import { HLInput } from '@platform-ui/highrise'

Props

Inline Props

PropTypeDefaultRequiredDescription
inlinebooleanfalsetrueMust be set to true to enable inline mode. Transforms the input into an inline editable field that blends with surrounding content until activated
showInlineCTAbooleanfalsefalseAdds confirm (✓) and cancel (×) buttons that appear during editing, requiring explicit user action to save or discard changes
showInlineBottomBorderbooleantruefalseControls the visibility of the bottom border in inline mode - useful for matching different design contexts
showSavedIconbooleanfalsefalseDeprecated: Use triggerSavedIcon() and clearSavedIcon() methods instead to programmatically control saved icon visibility

Common Props

NameTypeDefaultDescription
id *string | undefinedundefinedThe id of the element
modelValuestring''The value of the input
type'text' | 'textarea' | 'password' | 'tel' | 'email' | 'url''text'The type of the input
readonlybooleanfalseIf true, the input is read-only
rowsnumber3Number of rows for textarea
clearablebooleanfalseIf true, a clear button is shown
size'lg' | 'md' | 'sm' | 'xs' | '2xs' | '3xs''sm'The size of the input
placeholderstring | undefinedundefinedPlaceholder text for the input
autosizeboolean | AutosizeConfig | undefinedundefinedIf true, the textarea auto-resizes
maxlengthnumber | undefinedundefinedMaximum number of characters allowed
minlengthnumber | undefinedundefinedMinimum number of characters required
loadingboolean | undefinedundefinedIf true, a loading indicator is shown
showCountboolean | undefinedundefinedIf true, character count is shown
disabledboolean | undefinedundefinedIf true, the input is disabled
inputPropsObjectundefinedAdditional properties for the input element
showPasswordOn'mousedown' | undefined | 'click'undefinedEvent to show the password in password input
prefixIconstring | undefinedundefinedsrc of the image to render
suffixIconstring | undefinedundefinedsrc of the image to render
suffixIconTooltipContentstring | undefinedundefinedTooltip content of suffix icon
textAlign'start' | 'center' | 'end'startText,Placeholder alignment of the input
fontSizestring | undefinedundefinedFont size of the input
fontWeightstring | undefinedundefinedFont weight of the input

Emits

Inline Emits

NameParametersDescription
@confirm(value: string)Emitted when user confirms the input in inline mode. The confirmed value is passed as the parameter
@cancel() => voidEmitted when user cancels the input in inline mode. The value is automatically restored to the previous value

Common Emits

NameDefaultTrigger
@update:modelValue(value: string | [string, string] | number | null) => voidWhen the input value changes
@change(value: string) => voidWhen native change event is fired
@focus(FocusEvent) => voidWhen the input is focused
@blur(FocusEvent) => voidWhen the input is blurred
@keydown(event: KeyboardEvent) => voidWhen the keydown event is fired

Slots

Inline Slots

NameDescription
edit-actionsContent to show on hover in inline mode

Common Slots

NameParametersDescription
default()The default content slot
prefix()Prefix content slot
suffix()Suffix content slot

Methods

Inline Methods

MethodTypeDescription
triggerSavedIcon()() => voidProgrammatically triggers the saved icon to appear. Useful for showing confirmation after async operations
clearSavedIcon()() => voidProgrammatically clears the saved icon. Useful for resetting the saved state

Common Methods

MethodTypeDescription
focus()() => voidFocuses the input
blur()() => voidBlurs the input
select()() => voidSelects the input
scrollTo(value: number)(value: number) => voidScrolls the input to a specific position