Skip to content

Commit

Permalink
fix
Browse files Browse the repository at this point in the history
  • Loading branch information
lukasoppermann committed Dec 14, 2024
1 parent 5ddd7c6 commit e719ffe
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 4 deletions.
1 change: 1 addition & 0 deletions scripts/utilities/validateTokenWithSchema.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ export type validationErrors = {

const unpackErrorDetails = details => {
const errorObjectByCode = {
//eslint-disable-next-line camelcase
invalid_union: 'unionErrors',
}
return {
Expand Down
5 changes: 2 additions & 3 deletions scripts/validateTokenJson.ts
Original file line number Diff line number Diff line change
Expand Up @@ -68,12 +68,11 @@ if (getFlag('--silent') === null) {
for (const path of Object.keys(fail.errorsByPath)) {
// eslint-disable-next-line no-console
console.log(`\nPath: \u001b[34;1m\u001b[1m${path}\u001b[0m`)

console.log(fail.errorsByPath)
// eslint-disable-next-line no-console
console.log(
fail.errorsByPath[path]
.map(
({message, code, path, errors}) =>
({message, code, errors}) =>
`${message.replace(/\*\*(.*?)\*\*/g, '- \u001b[31;1m\u001b[1m$1\u001b[0m').replace(/\n(?!-)/g, '\n ↳ ')}, code: ${code}, errors:\n ${errors
.map(error => {
return `- ${error.issues[0].code}: ${error.issues[0].message}`
Expand Down
2 changes: 1 addition & 1 deletion src/transformers/colorAlphaToCss.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import {Transform, TransformedToken} from 'style-dictionary/types'
import type {Transform, TransformedToken} from 'style-dictionary/types'
import {isColorWithAlpha} from '../filters/isColorWithAlpha.js'
import {getTokenValue} from './utilities/getTokenValue.js'

Expand Down

0 comments on commit e719ffe

Please sign in to comment.