( styleField: StyleField<T> | undefined, args: T, )
| 180 | }; |
| 181 | |
| 182 | export const styleFieldToCssObject = <T extends MinCallbackArg>( |
| 183 | styleField: StyleField<T> | undefined, |
| 184 | args: T, |
| 185 | ) => { |
| 186 | if (typeof styleField === "object") return styleField; |
| 187 | if (typeof styleField === "function") { |
| 188 | const result = styleField(args); |
| 189 | |
| 190 | if (typeof result === "object") return result; |
| 191 | } |
| 192 | |
| 193 | return {}; |
| 194 | }; |
| 195 | |
| 196 | export const contentFieldToContent = <T extends MinCallbackArg>( |
| 197 | contentField: ContentField<T> | undefined, |
no outgoing calls
no test coverage detected