Files
manja_ui_dev/dist/assets/Buttons-But-L6eX.js
T
sean d26db06f74
NPM Installation / build (16.x, ubuntu-latest) (push) Has been cancelled
NPM Installation / build (16.x, windows-latest) (push) Has been cancelled
NPM Installation / build (17.x, ubuntu-latest) (push) Has been cancelled
NPM Installation / build (17.x, windows-latest) (push) Has been cancelled
NPM Installation / build (18.x, ubuntu-latest) (push) Has been cancelled
NPM Installation / build (18.x, windows-latest) (push) Has been cancelled
all data hide
2026-06-25 09:44:52 +07:00

1 line
12 KiB
JavaScript

import{Bt as e,It as t,Jt as n,Lt as r,Mt as i,Pt as a,Qt as o,Vt as s,Xt as c,an as l,qt as u,zt as d}from"./index-qNrWYJXL.js";var f={},p={class:`d-grid gap-2`},m={class:`d-grid gap-2 d-md-block`},h={class:`d-grid gap-2 col-6 mx-auto`},g={class:`d-grid gap-2 d-md-flex justify-content-md-end`};function _(i,f){let _=c(`DocsComponents`),v=c(`CCardHeader`),y=c(`CCol`),b=c(`CButton`),x=c(`CRow`),S=c(`DocsExample`),C=c(`CCardBody`),w=c(`CCard`),T=c(`CIcon`);return u(),r(x,null,{default:o(()=>[s(y,{xs:12},{default:o(()=>[s(_,{href:`components/button.html`}),s(w,{class:`mb-4`},{default:o(()=>[s(v,null,{default:o(()=>[...f[0]||=[t(`strong`,null,`Vue Button`,-1)]]),_:1}),s(C,null,{default:o(()=>[f[1]||=t(`p`,{class:`text-body-secondary small`},` CoreUI includes a bunch of predefined buttons components, each serving its own semantic purpose. Buttons show what action will happen when the user clicks or touches it. CoreUI buttons are used to initialize operations, both in the background or foreground of an experience. `,-1),s(S,{href:`components/button.html`},{default:o(()=>[(u(),d(a,null,n([`normal`,`active`,`disabled`],t=>s(x,{key:t,class:`align-items-center mb-3`},{default:o(()=>[s(y,{xs:12,xl:2,class:`mb-3 mb-xl-0`},{default:o(()=>[e(l(t.charAt(0).toUpperCase()+t.slice(1)),1)]),_:2},1024),s(y,{xs:``},{default:o(()=>[(u(),d(a,null,n([`primary`,`secondary`,`success`,`danger`,`warning`,`info`,`light`,`dark`],n=>s(b,{key:n,color:n,active:t===`active`,disabled:t===`disabled`},{default:o(()=>[e(l(n.charAt(0).toUpperCase()+n.slice(1)),1)]),_:2},1032,[`color`,`active`,`disabled`])),64))]),_:2},1024)]),_:2},1024)),64))]),_:1})]),_:1})]),_:1})]),_:1}),s(y,{xs:12},{default:o(()=>[s(w,{class:`mb-4`},{default:o(()=>[s(v,null,{default:o(()=>[...f[2]||=[t(`strong`,null,`Vue Button`,-1),e(),t(`small`,null,`with icons`,-1)]]),_:1}),s(C,null,{default:o(()=>[f[3]||=t(`p`,{class:`text-body-secondary small`},[e(` You can combine button with our `),t(`a`,{href:`https://coreui.io/icons/`},`CoreUI Icons`),e(`. `)],-1),s(S,{href:`components/button.html`},{default:o(()=>[(u(),d(a,null,n([`normal`,`active`,`disabled`],t=>s(x,{key:t,class:`align-items-center mb-3`},{default:o(()=>[s(y,{xs:12,xl:2,class:`mb-3 mb-xl-0`},{default:o(()=>[e(l(t.charAt(0).toUpperCase()+t.slice(1)),1)]),_:2},1024),s(y,{xs:``},{default:o(()=>[(u(),d(a,null,n([`primary`,`secondary`,`success`,`danger`,`warning`,`info`,`light`,`dark`],n=>s(b,{key:n,color:n,active:t===`active`,disabled:t===`disabled`},{default:o(()=>[s(T,{icon:`cil-bell`,class:`me-2`}),e(` `+l(n.charAt(0).toUpperCase()+n.slice(1)),1)]),_:2},1032,[`color`,`active`,`disabled`])),64))]),_:2},1024)]),_:2},1024)),64))]),_:1})]),_:1})]),_:1})]),_:1}),s(y,{xs:12},{default:o(()=>[s(w,{class:`mb-4`},{default:o(()=>[s(v,null,{default:o(()=>[...f[4]||=[t(`strong`,null,`Vue Button`,-1),e(),t(`small`,null,`Button components`,-1)]]),_:1}),s(C,null,{default:o(()=>[f[7]||=t(`p`,{class:`text-body-secondary small`},[e(` The `),t(`code`,null,`<CButton>`),e(` component are designed for `),t(`code`,null,`<button>`),e(` , `),t(`code`,null,`<a>`),e(` or `),t(`code`,null,`<input>`),e(` elements (though some browsers may apply a slightly different rendering). `)],-1),f[8]||=t(`p`,{class:`text-body-secondary small`},[e(` If you're using `),t(`code`,null,`<CButton>`),e(` component as `),t(`code`,null,`<a>`),e(` elements that are used to trigger functionality ex. collapsing content, these links should be given a `),t(`code`,null,`role="button"`),e(` to adequately communicate their meaning to assistive technologies such as screen readers. `)],-1),s(S,{href:`components/button.html#button-components`},{default:o(()=>[s(b,{as:`a`,color:`primary`,href:`#`,role:`button`},{default:o(()=>[...f[5]||=[e(` Link `,-1)]]),_:1}),s(b,{type:`submit`,color:`primary`},{default:o(()=>[...f[6]||=[e(` Button `,-1)]]),_:1}),s(b,{as:`input`,type:`button`,color:`primary`,value:`Input`}),s(b,{as:`input`,type:`submit`,color:`primary`,value:`Submit`}),s(b,{as:`input`,type:`reset`,color:`primary`,value:`Reset`})]),_:1})]),_:1})]),_:1})]),_:1}),s(y,{xs:12},{default:o(()=>[s(w,{class:`mb-4`},{default:o(()=>[s(v,null,{default:o(()=>[...f[9]||=[t(`strong`,null,`Vue Button`,-1),e(),t(`small`,null,`outline`,-1)]]),_:1}),s(C,null,{default:o(()=>[f[10]||=t(`p`,{class:`text-body-secondary small`},[e(` If you need a button, but without the strong background colors. Set `),t(`code`,null,`variant="outline"`),e(` prop to remove all background colors. `)],-1),s(S,{href:`components/button.html#outline-buttons`},{default:o(()=>[(u(),d(a,null,n([`normal`,`active`,`disabled`],t=>s(x,{key:t,class:`align-items-center mb-3`},{default:o(()=>[s(y,{xs:12,xl:2,class:`mb-3 mb-xl-0`},{default:o(()=>[e(l(t.charAt(0).toUpperCase()+t.slice(1)),1)]),_:2},1024),s(y,{xs:``},{default:o(()=>[(u(),d(a,null,n([`primary`,`secondary`,`success`,`danger`,`warning`,`info`,`light`,`dark`],n=>s(b,{key:n,color:n,active:t===`active`,disabled:t===`disabled`,variant:`outline`},{default:o(()=>[e(l(n.charAt(0).toUpperCase()+n.slice(1)),1)]),_:2},1032,[`color`,`active`,`disabled`])),64))]),_:2},1024)]),_:2},1024)),64))]),_:1})]),_:1})]),_:1})]),_:1}),s(y,{xs:12},{default:o(()=>[s(w,{class:`mb-4`},{default:o(()=>[s(v,null,{default:o(()=>[...f[11]||=[t(`strong`,null,`Vue Button`,-1),e(),t(`small`,null,`ghost`,-1)]]),_:1}),s(C,null,{default:o(()=>[f[12]||=t(`p`,{class:`text-body-secondary small`},[e(` If you need a ghost variant of button, set `),t(`code`,null,`variant="ghost"`),e(` prop to remove all background colors. `)],-1),s(S,{href:`components/button.html#ghost-buttons`},{default:o(()=>[(u(),d(a,null,n([`normal`,`active`,`disabled`],t=>s(x,{key:t,class:`align-items-center mb-3`},{default:o(()=>[s(y,{xs:12,xl:2,class:`mb-3 mb-xl-0`},{default:o(()=>[e(l(t.charAt(0).toUpperCase()+t.slice(1)),1)]),_:2},1024),s(y,{xs:``},{default:o(()=>[(u(),d(a,null,n([`primary`,`secondary`,`success`,`danger`,`warning`,`info`,`light`,`dark`],n=>s(b,{key:n,color:n,active:t===`active`,disabled:t===`disabled`,variant:`ghost`},{default:o(()=>[s(T,{icon:`cil-bell`,class:`me-2`}),e(` `+l(n.charAt(0).toUpperCase()+n.slice(1)),1)]),_:2},1032,[`color`,`active`,`disabled`])),64))]),_:2},1024)]),_:2},1024)),64))]),_:1})]),_:1})]),_:1})]),_:1}),s(y,{xs:12},{default:o(()=>[s(w,{class:`mb-4`},{default:o(()=>[s(v,null,{default:o(()=>[...f[13]||=[t(`strong`,null,`Vue Button`,-1),e(),t(`small`,null,`Sizes`,-1)]]),_:1}),s(C,null,{default:o(()=>[f[18]||=t(`p`,{class:`text-body-secondary small`},[e(` Larger or smaller buttons? Add `),t(`code`,null,`size="lg"`),e(` or `),t(`code`,null,`size="sm"`),e(` for additional sizes. `)],-1),s(S,{href:`components/button.html#sizes`},{default:o(()=>[s(b,{color:`primary`,size:`lg`},{default:o(()=>[...f[14]||=[e(` Large button `,-1)]]),_:1}),s(b,{color:`secondary`,size:`lg`},{default:o(()=>[...f[15]||=[e(` Large button `,-1)]]),_:1})]),_:1}),s(S,{href:`components/button.html#sizes`},{default:o(()=>[s(b,{color:`primary`,size:`sm`},{default:o(()=>[...f[16]||=[e(` Small button `,-1)]]),_:1}),s(b,{color:`secondary`,size:`sm`},{default:o(()=>[...f[17]||=[e(` Small button `,-1)]]),_:1})]),_:1})]),_:1})]),_:1})]),_:1}),s(y,{xs:12},{default:o(()=>[s(w,{class:`mb-4`},{default:o(()=>[s(v,null,{default:o(()=>[...f[19]||=[t(`strong`,null,`Vue Button`,-1),e(),t(`small`,null,`Pill`,-1)]]),_:1}),s(C,null,{default:o(()=>[s(S,{href:`components/button.html#pill-buttons`},{default:o(()=>[(u(),d(a,null,n([`primary`,`secondary`,`success`,`danger`,`warning`,`info`,`light`,`dark`],t=>s(b,{key:t,color:t,shape:`rounded-pill`},{default:o(()=>[e(l(t.charAt(0).toUpperCase()+t.slice(1)),1)]),_:2},1032,[`color`])),64))]),_:1})]),_:1})]),_:1})]),_:1}),s(y,{xs:12},{default:o(()=>[s(w,{class:`mb-4`},{default:o(()=>[s(v,null,{default:o(()=>[...f[20]||=[t(`strong`,null,`Vue Button`,-1),e(),t(`small`,null,`Square`,-1)]]),_:1}),s(C,null,{default:o(()=>[s(S,{href:`components/button.html#square`},{default:o(()=>[(u(),d(a,null,n([`primary`,`secondary`,`success`,`danger`,`warning`,`info`,`light`,`dark`],t=>s(b,{key:t,color:t,shape:`rounded-0`},{default:o(()=>[e(l(t.charAt(0).toUpperCase()+t.slice(1)),1)]),_:2},1032,[`color`])),64))]),_:1})]),_:1})]),_:1})]),_:1}),s(y,{xs:12},{default:o(()=>[s(w,{class:`mb-4`},{default:o(()=>[s(v,null,{default:o(()=>[...f[21]||=[t(`strong`,null,`Vue Button`,-1),e(),t(`small`,null,`Disabled state`,-1)]]),_:1}),s(C,null,{default:o(()=>[f[26]||=t(`p`,{class:`text-body-secondary small`},[e(` Add the `),t(`code`,null,`disabled`),e(` boolean prop to any `),t(`code`,null,`<CButton>`),e(` component to make buttons look inactive. Disabled button has `),t(`code`,null,`pointer-events: none`),e(` applied to, disabling hover and active states from triggering. `)],-1),s(S,{href:`components/button.html#disabled-state`},{default:o(()=>[s(b,{color:`primary`,size:`lg`,disabled:``},{default:o(()=>[...f[22]||=[e(` Primary button `,-1)]]),_:1}),s(b,{color:`secondary`,size:`lg`,disabled:``},{default:o(()=>[...f[23]||=[e(` Button `,-1)]]),_:1})]),_:1}),f[27]||=t(`p`,{class:`text-body-secondary small`},[e(` Disabled buttons using the `),t(`code`,null,`<a>`),e(` component act a little different: `)],-1),f[28]||=t(`p`,{class:`text-body-secondary small`},[t(`code`,null,`<a>`),e(`s don'tsupport the `),t(`code`,null,`disabled`),e(` attribute, so CoreUI has to add `),t(`code`,null,`.disabled`),e(` class to make buttons look inactive. CoreUI also has to add to the disabled button component `),t(`code`,null,`aria-disabled="true"`),e(` attribute to show the state of the component to assistive technologies. `)],-1),s(S,{href:`components/button.html#disabled-state`},{default:o(()=>[s(b,{as:`a`,href:`#`,color:`primary`,size:`lg`,disabled:``},{default:o(()=>[...f[24]||=[e(` Primary link `,-1)]]),_:1}),s(b,{as:`a`,href:`#`,color:`secondary`,size:`lg`,disabled:``},{default:o(()=>[...f[25]||=[e(` Link `,-1)]]),_:1})]),_:1})]),_:1})]),_:1})]),_:1}),s(y,{xs:12},{default:o(()=>[s(w,{class:`mb-4`},{default:o(()=>[s(v,null,{default:o(()=>[...f[29]||=[t(`strong`,null,`Vue Button`,-1),e(),t(`small`,null,`Block buttons`,-1)]]),_:1}),s(C,null,{default:o(()=>[f[38]||=t(`p`,{class:`text-body-secondary small`},` Create buttons that span the full width of a parent—by using utilities. `,-1),s(S,{href:`components/button.html#block-buttons`},{default:o(()=>[t(`div`,p,[s(b,{color:`primary`},{default:o(()=>[...f[30]||=[e(`Button`,-1)]]),_:1}),s(b,{color:`primary`},{default:o(()=>[...f[31]||=[e(`Button`,-1)]]),_:1})])]),_:1}),f[39]||=t(`p`,{class:`text-body-secondary small`},[e(` Here we create a responsive variation, starting with vertically stacked buttons until the `),t(`code`,null,`md`),e(` breakpoint, where `),t(`code`,null,`.d-md-block`),e(` replaces the `),t(`code`,null,`.d-grid`),e(` class, thus nullifying the `),t(`code`,null,`gap-2`),e(` utility. Resize your browser to see them change. `)],-1),s(S,{href:`components/button.html#block-buttons`},{default:o(()=>[t(`div`,m,[s(b,{color:`primary`},{default:o(()=>[...f[32]||=[e(`Button`,-1)]]),_:1}),s(b,{color:`primary`},{default:o(()=>[...f[33]||=[e(`Button`,-1)]]),_:1})])]),_:1}),f[40]||=t(`p`,{class:`text-body-secondary small`},[e(` You can adjust the width of your block buttons with grid column width classes. For example, for a half-width "block button", use `),t(`code`,null,`.col-6`),e(`. Center it horizontally with `),t(`code`,null,`.mx-auto`),e(`, too. `)],-1),s(S,{href:`components/button.html#block-buttons`},{default:o(()=>[t(`div`,h,[s(b,{color:`primary`},{default:o(()=>[...f[34]||=[e(`Button`,-1)]]),_:1}),s(b,{color:`primary`},{default:o(()=>[...f[35]||=[e(`Button`,-1)]]),_:1})])]),_:1}),f[41]||=t(`p`,{class:`text-body-secondary small`},` Additional utilities can be used to adjust the alignment of buttons when horizontal. Here we've taken our previous responsive example and added some flex utilities and a margin utility on the button to right align the buttons when they're no longer stacked. `,-1),s(S,{href:`components/button.html#block-buttons`},{default:o(()=>[t(`div`,g,[s(b,{color:`primary`,class:`me-md-2`},{default:o(()=>[...f[36]||=[e(` Button `,-1)]]),_:1}),s(b,{color:`primary`},{default:o(()=>[...f[37]||=[e(`Button`,-1)]]),_:1})])]),_:1})]),_:1})]),_:1})]),_:1})]),_:1})}var v=i(f,[[`render`,_]]);export{v as default};