wip(sde): Handle package dependencies
This commit is contained in:
parent
78b199ce44
commit
e0386a441b
23 changed files with 662 additions and 614 deletions
|
@ -94,7 +94,13 @@ yarn-error.log*
|
|||
from: 'sde/env.local',
|
||||
to: 'sde/.env.local',
|
||||
},
|
||||
...downloads,
|
||||
...downloads.sites,
|
||||
],
|
||||
packages: downloads.pkgs.map((file) => ({
|
||||
from: file,
|
||||
to: `pkgs/${file}`,
|
||||
})),
|
||||
},
|
||||
}
|
||||
|
||||
console.log(config.fetch.pkgs)
|
||||
|
|
File diff suppressed because it is too large
Load diff
|
@ -35,7 +35,7 @@ const getFiles = async (dir) => {
|
|||
.map((file) => file.split('/sites/').pop())
|
||||
}
|
||||
|
||||
const searchFiles = async (dirs) => {
|
||||
const searchFiles = async (dirs, split = '/sites/') => {
|
||||
/*
|
||||
* Figure out what directory to spawn the child process in
|
||||
*/
|
||||
|
@ -76,7 +76,7 @@ const searchFiles = async (dirs) => {
|
|||
...stdout
|
||||
.split('\n')
|
||||
.filter((entry) => entry.length > 2)
|
||||
.map((file) => file.split('/sites/').pop())
|
||||
.map((file) => file.split(split).pop())
|
||||
)
|
||||
}
|
||||
|
||||
|
@ -97,8 +97,9 @@ const buildFileList = async () => {
|
|||
'../../sites/shared/themes',
|
||||
'../../sites/shared/prebuild/data',
|
||||
])
|
||||
const pkgs = await searchFiles(['../../packages/react-components/src'], '/packages/')
|
||||
|
||||
return [...sde, ...shared]
|
||||
return { sites: [...sde, ...shared], pkgs }
|
||||
}
|
||||
|
||||
/*
|
||||
|
|
|
@ -1,3 +1,4 @@
|
|||
// __SDEFILE__ - This file is a dependency for the stand-alone environment
|
||||
// Components
|
||||
// Pattern
|
||||
import { Pattern as PatternComponent } from './pattern/index.mjs'
|
||||
|
|
|
@ -1,3 +1,4 @@
|
|||
// __SDEFILE__ - This file is a dependency for the stand-alone environment
|
||||
// eslint-disable-next-line no-unused-vars
|
||||
import React, { forwardRef } from 'react'
|
||||
import { defaultPatternComponents } from '../pattern/index.mjs'
|
||||
|
|
|
@ -1,3 +1,4 @@
|
|||
// __SDEFILE__ - This file is a dependency for the stand-alone environment
|
||||
// Components
|
||||
import { Path } from '../pattern/path.mjs'
|
||||
import { getProps } from '../pattern/utils.mjs'
|
||||
|
|
|
@ -1,3 +1,4 @@
|
|||
// __SDEFILE__ - This file is a dependency for the stand-alone environment
|
||||
// Components
|
||||
import { Point } from '../pattern/point.mjs'
|
||||
import { withinPartBounds } from '../pattern/utils.mjs'
|
||||
|
|
|
@ -1,3 +1,4 @@
|
|||
// __SDEFILE__ - This file is a dependency for the stand-alone environment
|
||||
// eslint-disable-next-line no-unused-vars
|
||||
import React from 'react'
|
||||
|
||||
|
|
|
@ -1,3 +1,4 @@
|
|||
// __SDEFILE__ - This file is a dependency for the stand-alone environment
|
||||
// eslint-disable-next-line no-unused-vars
|
||||
import React from 'react'
|
||||
import sanitize from 'html-react-parser'
|
||||
|
|
|
@ -1,3 +1,4 @@
|
|||
// __SDEFILE__ - This file is a dependency for the stand-alone environment
|
||||
// eslint-disable-next-line no-unused-vars
|
||||
import React from 'react'
|
||||
|
||||
|
|
|
@ -1,3 +1,4 @@
|
|||
// __SDEFILE__ - This file is a dependency for the stand-alone environment
|
||||
// eslint-disable-next-line no-unused-vars
|
||||
import React, { forwardRef } from 'react'
|
||||
|
||||
|
|
|
@ -1,3 +1,4 @@
|
|||
// __SDEFILE__ - This file is a dependency for the stand-alone environment
|
||||
// eslint-disable-next-line no-unused-vars
|
||||
import React, { forwardRef } from 'react'
|
||||
// Components that can be swizzled
|
||||
|
|
|
@ -1,3 +1,4 @@
|
|||
// __SDEFILE__ - This file is a dependency for the stand-alone environment
|
||||
// eslint-disable-next-line no-unused-vars
|
||||
import React, { forwardRef } from 'react'
|
||||
import { getId, getProps } from './utils.mjs'
|
||||
|
|
|
@ -1,3 +1,4 @@
|
|||
// __SDEFILE__ - This file is a dependency for the stand-alone environment
|
||||
// eslint-disable-next-line no-unused-vars
|
||||
import React from 'react'
|
||||
import { getId, getProps } from './utils.mjs'
|
||||
|
|
|
@ -1,3 +1,4 @@
|
|||
// __SDEFILE__ - This file is a dependency for the stand-alone environment
|
||||
// eslint-disable-next-line no-unused-vars
|
||||
import React from 'react'
|
||||
import { withinPartBounds } from './utils.mjs'
|
||||
|
|
|
@ -1,3 +1,4 @@
|
|||
// __SDEFILE__ - This file is a dependency for the stand-alone environment
|
||||
// eslint-disable-next-line no-unused-vars
|
||||
import React from 'react'
|
||||
import { getProps } from './utils.mjs'
|
||||
|
|
|
@ -1,3 +1,4 @@
|
|||
// __SDEFILE__ - This file is a dependency for the stand-alone environment
|
||||
// eslint-disable-next-line no-unused-vars
|
||||
import React from 'react'
|
||||
import { getProps } from './utils.mjs'
|
||||
|
|
|
@ -1,3 +1,4 @@
|
|||
// __SDEFILE__ - This file is a dependency for the stand-alone environment
|
||||
// eslint-disable-next-line no-unused-vars
|
||||
import React from 'react'
|
||||
import { forwardRef } from 'react'
|
||||
|
|
|
@ -1,3 +1,4 @@
|
|||
// __SDEFILE__ - This file is a dependency for the stand-alone environment
|
||||
// eslint-disable-next-line no-unused-vars
|
||||
import React from 'react'
|
||||
import { translateStrings } from './utils.mjs'
|
||||
|
|
|
@ -1,3 +1,4 @@
|
|||
// __SDEFILE__ - This file is a dependency for the stand-alone environment
|
||||
// eslint-disable-next-line no-unused-vars
|
||||
import React from 'react'
|
||||
|
||||
|
|
|
@ -29,7 +29,7 @@ import { ModalDesignPicker } from './design-picker.mjs'
|
|||
|
||||
import { NavButton, NavSpacer } from 'shared/components/header.mjs'
|
||||
|
||||
export const ns = nsMerge('sde', 'header', 'sections', themeNs, localeNs)
|
||||
export const ns = nsMerge('sde', 'header', 'sections', 'susi', themeNs, localeNs)
|
||||
|
||||
const NavIcons = ({ setModal }) => {
|
||||
const { t } = useTranslation(['header'])
|
||||
|
@ -74,7 +74,7 @@ const NavIcons = ({ setModal }) => {
|
|||
<I18nIcon className={iconSize} />
|
||||
</NavButton>
|
||||
<NavSpacer />
|
||||
<NavButton href="/signin" label={t('account:signin')} color={spectrum[8]}>
|
||||
<NavButton href="/signin" label={t('susi:signIn')} color={spectrum[8]}>
|
||||
<LockIcon className={iconSize} />
|
||||
</NavButton>
|
||||
</>
|
||||
|
|
|
@ -8,6 +8,7 @@ import { Popout, ns as popoutNs } from 'shared/components/popout/index.mjs'
|
|||
import { PageLink, WebLink } from 'shared/components/link.mjs'
|
||||
import { FreeSewingIcon } from 'shared/components/icons.mjs'
|
||||
import { collection } from 'site/hooks/use-design.mjs'
|
||||
import { version } from '@freesewing/core'
|
||||
|
||||
const ns = ['sde', ...pageNs, ...popoutNs]
|
||||
/*
|
||||
|
@ -45,6 +46,7 @@ const HomePage = ({ page }) => {
|
|||
<WebLink href="https://freesewing.org/patrons/join" txt={t('sde:ps')} />.
|
||||
</p>
|
||||
</div>
|
||||
<p className="text-center text-sm mt-12 opacity-60">FreeSewing v{version}</p>
|
||||
</PageWrapper>
|
||||
)
|
||||
}
|
||||
|
|
|
@ -1,3 +1,4 @@
|
|||
// __SDEFILE__ - This file is a dependency for the stand-alone environment
|
||||
// Dependencies
|
||||
import { measurements } from 'config/measurements.mjs'
|
||||
import { measurements as designMeasurements } from 'shared/prebuild/data/design-measurements.mjs'
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue