Tokens for Divider

pull/5756/head
Cagatay Civici 2024-05-11 15:55:56 +03:00
parent e276e517b0
commit e739afbf3f
3 changed files with 34 additions and 6 deletions

View File

@ -6,8 +6,8 @@ const theme = ({ dt }) => `
width: 100%; width: 100%;
position: relative; position: relative;
align-items: center; align-items: center;
margin: 1rem 0; margin: ${dt('divider.horizontal.margin')};
padding: 0 1rem; padding: ${dt('divider.horizontal.padding')};
} }
.p-divider-horizontal:before { .p-divider-horizontal:before {
@ -21,7 +21,7 @@ const theme = ({ dt }) => `
} }
.p-divider-horizontal .p-divider-content { .p-divider-horizontal .p-divider-content {
padding: 0 0.5rem; padding: ${dt('divider.horizontal.content.padding')};
} }
.p-divider-vertical { .p-divider-vertical {
@ -30,8 +30,8 @@ const theme = ({ dt }) => `
display: flex; display: flex;
position: relative; position: relative;
justify-content: center; justify-content: center;
margin: 0 1rem; margin: ${dt('divider.vertical.margin')};
padding: 1rem 0; padding: ${dt('divider.vertical.padding')};
} }
.p-divider-vertical:before { .p-divider-vertical:before {
@ -45,7 +45,7 @@ const theme = ({ dt }) => `
} }
.p-divider.p-divider-vertical .p-divider-content { .p-divider.p-divider-vertical .p-divider-content {
padding: 0.5rem 0; padding: ${dt('divider.vertical.content.padding')};
} }
.p-divider-content { .p-divider-content {

View File

@ -5,5 +5,19 @@ export default {
content: { content: {
background: '{content.background}', background: '{content.background}',
color: '{text.color}' color: '{text.color}'
},
horizontal: {
margin: '1rem 0',
padding: '0 1rem',
content: {
padding: '0 0.5rem'
}
},
vertical: {
margin: '0 1rem',
padding: '0.5rem 0',
content: {
padding: '0.625rem 0'
}
} }
}; };

View File

@ -5,5 +5,19 @@ export default {
content: { content: {
background: '{content.background}', background: '{content.background}',
color: '{text.color}' color: '{text.color}'
},
horizontal: {
margin: '1.125rem 0',
padding: '0 1.125rem',
content: {
padding: '0 0.625rem'
}
},
vertical: {
margin: '0 1.125rem',
padding: '1.125rem 0',
content: {
padding: '0.625rem 0'
}
} }
}; };