@@ -69,7 +69,7 @@ description: Take picture from user's camera
6969 <p-card
7070 title="Any Title Should Here">
7171 <template #action>
72- <p-button color =" info " variant =" link " >Button Text</p-button >
72+ <p-button color =" info " variant =" link " style = " --p-button-md-padding-y : 0 ; --p-button-md-padding-x : 0 ; " >Button Text</p-button >
7373 </template >
7474 While here you will see the content of cards, everything goes here.
7575 If you need custom cards, take the component which more represent to
@@ -151,7 +151,7 @@ description: Take picture from user's camera
151151 title="Card with Sub-Section"
152152 sectioned>
153153 <template #action>
154- <p-button variant =" link " color =" info " >Button Text</p-button >
154+ <p-button variant =" link " color =" info " style = " --p-button-md-padding-y : 0 ; --p-button-md-padding-x : 0 ; " >Button Text</p-button >
155155 </template >
156156 <p-card-section >
157157 While here you will see the content of cards, everything goes here.
@@ -266,12 +266,67 @@ description: Take picture from user's camera
266266</template>
267267```
268268
269+ ## Spacing
270+ Card component features 4 distinct spacing variants that adjust the size and
271+ layout of the content within the card body. Each variant is designed to offer
272+ flexibility in presentation and to suit different design needs.
273+ There are ` sm ` , ` md ` , ` lg ` and ` xl ` . Default spacing are ` md ` .
274+ The spacing feature also work in ` Sectioned card ` .
275+
276+ <preview >
277+ <p-card spacing =" sm " >
278+ While here you will see the content of cards, everything goes here.
279+ If you need custom cards, take the component which more represent to
280+ what you need and detach it.
281+ </p-card >
282+ <p-card spacing =" md " >
283+ While here you will see the content of cards, everything goes here.
284+ If you need custom cards, take the component which more represent to
285+ what you need and detach it.
286+ </p-card >
287+ <p-card spacing =" lg " >
288+ While here you will see the content of cards, everything goes here.
289+ If you need custom cards, take the component which more represent to
290+ what you need and detach it.
291+ </p-card >
292+ <p-card spacing =" xl " >
293+ While here you will see the content of cards, everything goes here.
294+ If you need custom cards, take the component which more represent to
295+ what you need and detach it.
296+ </p-card >
297+ </preview >
298+
299+ ``` vue
300+ <template>
301+ <p-card spacing="sm">
302+ While here you will see the content of cards, everything goes here.
303+ If you need custom cards, take the component which more represent to
304+ what you need and detach it.
305+ </p-card>
306+ <p-card spacing="md">
307+ While here you will see the content of cards, everything goes here.
308+ If you need custom cards, take the component which more represent to
309+ what you need and detach it.
310+ </p-card>
311+ <p-card spacing="lg">
312+ While here you will see the content of cards, everything goes here.
313+ If you need custom cards, take the component which more represent to
314+ what you need and detach it.
315+ </p-card>
316+ <p-card spacing="xl">
317+ While here you will see the content of cards, everything goes here.
318+ If you need custom cards, take the component which more represent to
319+ what you need and detach it.
320+ </p-card>
321+ </template>
322+ ```
323+
269324## Variables
270325Card use local CSS variables on ` .card ` for enhanced real-time customization.
271326
272327``` sass
273- --p-card-padding-x : theme(spacing.6 );
274- --p-card-padding-y : theme(spacing.6 );
328+ --p-card-border-radius : theme(borderRadius.md );
329+ --p-card-inside-border-radius : theme(borderRadius.DEFAULT );
275330--p-card-bg: theme(backgroundColor.default.DEFAULT);
276331--p-card-bg-dark: theme(backgroundColor.dark.default.DEFAULT);
277332--p-card-border: theme(borderColor.default.DEFAULT);
@@ -286,12 +341,13 @@ Card use local CSS variables on `.card` for enhanced real-time customization.
286341
287342| Props | Type | Default | Description |
288343| ---------------| :---------:| :---------:| --------------------------------------------------------------|
289- | ` element ` | ` String ` | ` section ` | Card element, valid value is ` div ` , ` section ` , and ` article ` |
344+ | ` element ` | ` String ` | ` section ` | Card element, valid value are ` div ` , ` section ` and ` article ` |
290345| ` title ` | ` String ` | - | Card Header Title |
291346| ` sectioned ` | ` Boolean ` | ` false ` | Enable Card Section |
292347| ` disabled ` | ` Boolean ` | ` false ` | Disable (look-like) Card |
293348| ` callout ` | ` Boolean ` | ` false ` | Enable Callout |
294349| ` dismissable ` | ` Boolean ` | ` true ` | Show / Hide dismiss button |
350+ | ` spacing ` | ` String ` | ` md ` | Card spacing, valid value are ` sm ` , ` md ` , ` lg ` and ` xl ` |
295351
296352### Slots
297353| Name | Description |
0 commit comments