| 1 |
import * as typoPrefixs from "./typographyPrefixConstants"; |
| 2 |
import { AUTHOR_BOX_WRAPPER_PADDING, AUTHOR_BOX_BACKGROUND, AUTHOR_BOX_SIZE, AUTHOR_BOX_WRAPPER_MARGIN, AUTHOR_BOX_BORDER } from "./constants"; |
| 3 |
import { generateResponsiveRangeAttributes, generateBackgroundAttributes, generateTypographyAttributes, generateBorderShadowAttributes, generateDimensionsAttributes } from "../../../util/helpers"; |
| 4 |
|
| 5 |
const attributes = { |
| 6 |
// the following 4 attributes is must required for responsive options and asset generation for frontend |
| 7 |
// responsive control attributes ⬇ |
| 8 |
resOption: { |
| 9 |
type: "string", |
| 10 |
default: "Desktop", |
| 11 |
}, |
| 12 |
// blockId attribute for making unique className and other uniqueness ⬇ |
| 13 |
blockId: { |
| 14 |
type: "string", |
| 15 |
}, |
| 16 |
blockRoot: { |
| 17 |
type: "string", |
| 18 |
default: "better_docs", |
| 19 |
}, |
| 20 |
// blockMeta is for keeping all the styles ⬇ |
| 21 |
blockMeta: { |
| 22 |
type: "object", |
| 23 |
}, |
| 24 |
docAuthorColor:{ |
| 25 |
type: "string", |
| 26 |
default: "#667085", |
| 27 |
}, |
| 28 |
updatedTimeColor:{ |
| 29 |
type: "string", |
| 30 |
default: "#475467", |
| 31 |
}, |
| 32 |
...generateTypographyAttributes(Object.values(typoPrefixs)), |
| 33 |
...generateResponsiveRangeAttributes(AUTHOR_BOX_SIZE, { |
| 34 |
defaultRange: 40, |
| 35 |
}), |
| 36 |
...generateDimensionsAttributes(AUTHOR_BOX_WRAPPER_MARGIN), |
| 37 |
...generateDimensionsAttributes(AUTHOR_BOX_WRAPPER_PADDING), |
| 38 |
...generateBackgroundAttributes(AUTHOR_BOX_BACKGROUND, { |
| 39 |
defaultFillColor: '#ffffff', |
| 40 |
noOverlay: true, |
| 41 |
}), |
| 42 |
...generateBorderShadowAttributes(AUTHOR_BOX_BORDER), |
| 43 |
|
| 44 |
}; |
| 45 |
|
| 46 |
export default attributes; |
| 47 |
|