Skip to content

Commit

Permalink
Merge remote-tracking branch 'origin/main' into layout_max_height_calc
Browse files Browse the repository at this point in the history
  • Loading branch information
cmdcolin committed Aug 12, 2024
2 parents eed197c + 615b1e3 commit 99896db
Show file tree
Hide file tree
Showing 765 changed files with 5,926 additions and 5,487 deletions.
26 changes: 0 additions & 26 deletions .eslintignore

This file was deleted.

206 changes: 0 additions & 206 deletions .eslintrc.js

This file was deleted.

1 change: 0 additions & 1 deletion config/jest/babelTransform.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
// eslint-disable-next-line import/no-extraneous-dependencies
module.exports = require('babel-jest').default.createTransformer({
rootMode: 'upward',
})
3 changes: 1 addition & 2 deletions config/jest/console.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
const originalWarn = console.warn
const originalError = console.error

jest.spyOn(console, 'error').mockImplementation((...args) => {
Expand All @@ -14,5 +13,5 @@ jest.spyOn(console, 'error').mockImplementation((...args) => {
return undefined
}

return originalError.call(console, ...args)
originalError.call(console, ...args)
})
11 changes: 4 additions & 7 deletions config/jest/textEncoder.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,4 @@
import util from 'util'
if (!global.TextEncoder) {
global.TextEncoder = util.TextEncoder
}
if (!global.TextDecoder) {
global.TextDecoder = util.TextDecoder
}
import { TextEncoder, TextDecoder } from 'util'

global.TextEncoder = TextEncoder
global.TextDecoder = TextDecoder
22 changes: 10 additions & 12 deletions docs/generateConfigDocs.ts
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ interface Config {
}

function generateConfigDocs(files: string[]) {
const cwd = process.cwd() + '/'
const cwd = `${process.cwd()}/`
const contents = {} as Record<string, Config>
extractWithComment(files, obj => {
const fn = obj.filename
Expand All @@ -53,8 +53,8 @@ function generateConfigDocs(files: string[]) {
}
}
const current = contents[fn]
const name = rm(obj.comment, '#' + obj.type) || obj.name
const docs = filter(filter(obj.comment, '#' + obj.type), '#category')
const name = rm(obj.comment, `#${obj.type}`) || obj.name
const docs = filter(filter(obj.comment, `#${obj.type}`), '#category')
const code = removeComments(obj.node)
const id = slugify(name, { lower: true })

Expand Down Expand Up @@ -119,23 +119,21 @@ ${derives.code}
\`\`\`
`
: ''
const slotstr =
`${slots.length ? `### ${config.name} - Slots` : ''}\n` +
slots
// eslint-disable-next-line @typescript-eslint/no-explicit-any
.map(({ name, docs, code }: any) => {
return `#### slot: ${name}
const slotstr = `${slots.length ? `### ${config.name} - Slots` : ''}\n${slots
.map(({ name, docs, code }: any) => {
return `#### slot: ${name}
${docs}
\`\`\`js
${code}
\`\`\`
`
})
.join('\n')
})
.join('\n')}`

const dir = `website/docs/config`
const dir = 'website/docs/config'
try {
fs.mkdirSync(dir)
} catch (e) {}
Expand Down
Loading

0 comments on commit 99896db

Please sign in to comment.