For AI agents: the complete documentation index is available at https://payhon.github.io/AppKernia/llms.txt, the full documentation bundle is available at https://payhon.github.io/AppKernia/llms-full.txt, and this page is available as Markdown at https://payhon.github.io/AppKernia/mobile-components/modal-switch.md.

ak-modalak-switch

ak-modal

<ak-modal
  :open="confirming"
  :title="t('sessions.revoke.title')"
  :message="t('sessions.revoke.message', { device: selectedDevice })"
  :cancel-text="t('common.actions.cancel')"
  :confirm-text="t('sessions.actions.revoke')"
  @cancel="confirming = false"
  @confirm="revokeSession"
/>
属性类型默认值
openBooleanfalse
titleString''
messageString''
cancelTextString''
confirmTextString''

事件:cancelconfirm,均无参数。当前确认按钮固定使用 danger 变体,因此只用于危险/不可逆或安全敏感操作。

ak-switch

<ak-switch v-model="pushEnabled" @change="savePushPreference" />
属性类型默认值
modelValueBooleanfalse
事件参数
update:modelValuenextValue: boolean
changenextValue: boolean

当前实现为立即切换。远端保存失败时,页面负责回滚并显示可理解的错误,不能让 UI 与服务端事实长期不一致。