├── libs ├── ui │ ├── theme │ │ ├── index.ts │ │ ├── register.ts │ │ └── styles │ │ │ ├── global.css │ │ │ ├── variables.css │ │ │ └── global-standalone.css │ ├── hooks │ │ ├── index.ts │ │ ├── focus-trap │ │ │ ├── index.ts │ │ │ └── useFocusReturnToLast.ts │ │ ├── keyboard │ │ │ ├── index.ts │ │ │ ├── useHotkey.ts │ │ │ ├── types.ts │ │ │ └── lib.ts │ │ └── core │ │ │ ├── useUniversalLayoutEffect.ts │ │ │ ├── useVariableRef.ts │ │ │ ├── use-id.ts │ │ │ ├── useMergedCallback.ts │ │ │ ├── useDidUpdateEffect.ts │ │ │ ├── index.ts │ │ │ ├── useEventCallback.ts │ │ │ ├── useForkCallback.ts │ │ │ └── useForkRef.ts │ ├── lib │ │ ├── theme.ts │ │ ├── dom │ │ │ ├── index.ts │ │ │ ├── shared.ts │ │ │ ├── style.ts │ │ │ ├── events.ts │ │ │ ├── overflow.ts │ │ │ └── tabbable.ts │ │ └── refs.ts │ ├── types │ │ ├── index.ts │ │ ├── global.d.ts │ │ ├── common.ts │ │ ├── global.overrides.d.ts │ │ ├── theme.ts │ │ └── elements.ts │ ├── core │ │ ├── button │ │ │ ├── index.ts │ │ │ ├── button.stories.tsx │ │ │ └── button.tsx │ │ ├── transition │ │ │ ├── index.ts │ │ │ ├── types.ts │ │ │ ├── constants.ts │ │ │ ├── transition.tsx │ │ │ ├── useTransition.ts │ │ │ ├── transition.stories.tsx │ │ │ ├── Collapse.tsx │ │ │ └── transition.module.css │ │ ├── svg-icon │ │ │ ├── index.ts │ │ │ └── svg-icon.tsx │ │ ├── typography │ │ │ ├── index.ts │ │ │ ├── typography.stories.tsx │ │ │ └── typography.tsx │ │ ├── icon-button │ │ │ ├── index.ts │ │ │ └── icon-button.tsx │ │ ├── popover │ │ │ ├── index.ts │ │ │ ├── types.ts │ │ │ ├── popover.stories.tsx │ │ │ ├── usePopover.ts │ │ │ ├── lib.ts │ │ │ └── popover.tsx │ │ ├── card │ │ │ ├── index.ts │ │ │ ├── card.tsx │ │ │ └── paper.tsx │ │ ├── grid │ │ │ ├── index.ts │ │ │ ├── grid.tsx │ │ │ ├── grid.module.css │ │ │ └── spaced.tsx │ │ ├── modal │ │ │ ├── index.ts │ │ │ ├── backdrop.tsx │ │ │ ├── portal.tsx │ │ │ ├── modal-manager.ts │ │ │ ├── trap-focus.tsx │ │ │ └── modal.tsx │ │ ├── input │ │ │ ├── index.ts │ │ │ ├── input.tsx │ │ │ ├── types.ts │ │ │ ├── html.tsx │ │ │ └── input-box.tsx │ │ └── dialog │ │ │ ├── footer.tsx │ │ │ ├── content.tsx │ │ │ ├── index.ts │ │ │ ├── header.tsx │ │ │ ├── dialog.stories.tsx │ │ │ └── dialog.tsx │ ├── static │ │ └── icons │ │ │ ├── ArrowDropDown.svg │ │ │ ├── ArrowDropUp.svg │ │ │ ├── Add.svg │ │ │ ├── Warn.svg │ │ │ ├── Error.svg │ │ │ ├── Info.svg │ │ │ ├── KeyboardArrowDown.svg │ │ │ ├── KeyboardArrowLeft.svg │ │ │ ├── KeyboardArrowRight.svg │ │ │ ├── Done.svg │ │ │ ├── CalendarToday.svg │ │ │ ├── Visibility.svg │ │ │ ├── Help.svg │ │ │ ├── VisibilityOff.svg │ │ │ └── Notifications.svg │ ├── README.md │ ├── postcss.config.js │ ├── icons │ │ ├── ArrowDropUp.tsx │ │ ├── Add.tsx │ │ ├── ArrowDropDown.tsx │ │ ├── Warn.tsx │ │ ├── Done.tsx │ │ ├── KeyboardArrowDown.tsx │ │ ├── Error.tsx │ │ ├── KeyboardArrowLeft.tsx │ │ ├── KeyboardArrowRight.tsx │ │ ├── Info.tsx │ │ ├── CalendarToday.tsx │ │ ├── Visibility.tsx │ │ ├── Notifications.tsx │ │ ├── Help.tsx │ │ ├── VisibilityOff.tsx │ │ └── index.ts │ ├── .storybook │ │ ├── preview.js │ │ └── main.js │ ├── tsconfig.json │ ├── index.js │ ├── stories │ │ └── Icons │ │ │ ├── Icons.stories.mdx │ │ │ ├── IconPreviewButton.tsx │ │ │ └── icons-preview.tsx │ ├── .svgrrc.js │ ├── package.json │ └── tailwind.config.js ├── hooks │ ├── readme.md │ ├── index.ts │ ├── package.json │ └── common │ │ └── useRequiredContext.ts ├── utils │ ├── readme.md │ ├── core │ │ ├── object │ │ │ ├── assoc.ts │ │ │ └── create.ts │ │ ├── array │ │ │ ├── exclude.ts │ │ │ ├── difference.ts │ │ │ └── difference.test.ts │ │ ├── is-empty.ts │ │ ├── index.ts │ │ ├── function │ │ │ ├── core.ts │ │ │ ├── debounce.test.ts │ │ │ └── debounce.ts │ │ └── core.ts │ ├── package.json │ └── tsconfig.json └── config │ ├── readme.md │ ├── ts │ ├── node.json │ └── base.json │ ├── jest │ ├── ts-paths.js │ ├── index.js │ └── base.js │ ├── package.json │ └── next │ └── index.js ├── apps ├── client-web │ ├── .env │ ├── .gitignore │ ├── postcss.config.js │ ├── tailwind.config.js │ ├── pages │ │ ├── 404.tsx │ │ ├── _app.tsx │ │ ├── _error.tsx │ │ └── index.tsx │ ├── tsconfig.node.json │ ├── next-env.d.ts │ ├── tsconfig.json │ ├── next.config.js │ ├── README.md │ ├── .babelrc │ └── package.json └── todo-web │ ├── .env │ ├── .gitignore │ ├── shared │ └── types │ │ ├── index.ts │ │ └── task.ts │ ├── features │ ├── add-task │ │ ├── index.ts │ │ └── ui │ │ │ ├── index.ts │ │ │ └── Input.tsx │ ├── remove-task │ │ ├── index.ts │ │ └── ui.tsx │ └── toggle-task │ │ ├── index.ts │ │ └── ui.tsx │ ├── readme.md │ ├── entities │ └── task │ │ ├── ui │ │ ├── index.ts │ │ └── list-item.tsx │ │ ├── index.ts │ │ └── model.ts │ ├── pages │ ├── todos.tsx │ ├── 404.tsx │ ├── _app.tsx │ ├── _error.tsx │ └── index.tsx │ ├── postcss.config.js │ ├── tailwind.config.js │ ├── next-env.d.ts │ ├── tsconfig.json │ ├── next.config.js │ ├── package.json │ └── screens │ └── todos │ └── index.tsx ├── .prettierignore ├── .husky ├── pre-push ├── pre-commit └── commit-msg ├── .yarn ├── install-state.gz └── build-state.yml ├── _templates ├── ws │ └── new │ │ ├── readme.ejs.t │ │ ├── package.ejs.t │ │ └── prompt.js └── ui │ ├── new │ ├── prompt.js │ ├── index.ejs.t │ └── component.ejs.t │ └── add-component │ ├── add-export.ejs.t │ ├── add-type-export.ejs.t │ ├── prompt.js │ └── component.ejs.t ├── .eslintignore ├── tsconfig.node.json ├── .lintstagedrc ├── .editorconfig ├── .prettierrc ├── .yarnrc.yml ├── .dockerignore ├── jest.config.js ├── .gitignore ├── tsconfig.base.json ├── Taskfile.yaml ├── tsconfig.json ├── .github └── workflows │ └── pull-request.yaml ├── commitlint.config.js ├── docker-compose.yml ├── package.json ├── README.md ├── .eslintrc.js ├── Dockerfile └── .gitattributes /libs/ui/theme/index.ts: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /apps/client-web/.env: -------------------------------------------------------------------------------- 1 | ANALYZE=false 2 | -------------------------------------------------------------------------------- /apps/client-web/.gitignore: -------------------------------------------------------------------------------- 1 | .next/ 2 | -------------------------------------------------------------------------------- /apps/todo-web/.env: -------------------------------------------------------------------------------- 1 | ANALYZE=false 2 | -------------------------------------------------------------------------------- /apps/todo-web/.gitignore: -------------------------------------------------------------------------------- 1 | .next/ 2 | -------------------------------------------------------------------------------- /libs/ui/hooks/index.ts: -------------------------------------------------------------------------------- 1 | export * from './core'; 2 | -------------------------------------------------------------------------------- /apps/todo-web/shared/types/index.ts: -------------------------------------------------------------------------------- 1 | export * from './task'; 2 | -------------------------------------------------------------------------------- /apps/todo-web/features/add-task/index.ts: -------------------------------------------------------------------------------- 1 | export * from './ui'; 2 | -------------------------------------------------------------------------------- /libs/hooks/readme.md: -------------------------------------------------------------------------------- 1 | # @libs/hooks 2 | 3 | TODO Add description 4 | -------------------------------------------------------------------------------- /libs/utils/readme.md: -------------------------------------------------------------------------------- 1 | # @libs/utils 2 | 3 | TODO Add description 4 | -------------------------------------------------------------------------------- /.prettierignore: -------------------------------------------------------------------------------- 1 | .pnp.js 2 | .yarn/ 3 | node_modules/ 4 | **/.next/ 5 | -------------------------------------------------------------------------------- /apps/todo-web/features/remove-task/index.ts: -------------------------------------------------------------------------------- 1 | export * from './ui'; 2 | -------------------------------------------------------------------------------- /apps/todo-web/features/toggle-task/index.ts: -------------------------------------------------------------------------------- 1 | export * from './ui'; 2 | -------------------------------------------------------------------------------- /libs/config/readme.md: -------------------------------------------------------------------------------- 1 | # @libs/configs 2 | 3 | TODO Add description 4 | -------------------------------------------------------------------------------- /apps/todo-web/readme.md: -------------------------------------------------------------------------------- 1 | # @apps/todo-web 2 | 3 | TODO Add description 4 | -------------------------------------------------------------------------------- /.husky/pre-push: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | . "$(dirname "$0")/_/husky.sh" 3 | 4 | task check 5 | -------------------------------------------------------------------------------- /apps/todo-web/entities/task/ui/index.ts: -------------------------------------------------------------------------------- 1 | export { TaskListItem } from './list-item'; 2 | -------------------------------------------------------------------------------- /apps/todo-web/features/add-task/ui/index.ts: -------------------------------------------------------------------------------- 1 | export { AddTaskInput } from './Input'; 2 | -------------------------------------------------------------------------------- /.husky/pre-commit: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | . "$(dirname "$0")/_/husky.sh" 3 | 4 | yarn lint-staged 5 | -------------------------------------------------------------------------------- /libs/hooks/index.ts: -------------------------------------------------------------------------------- 1 | export { useRequiredContext } from './common/useRequiredContext'; 2 | -------------------------------------------------------------------------------- /.husky/commit-msg: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | . "$(dirname "$0")/_/husky.sh" 3 | 4 | yarn commitlint --edit $1 5 | -------------------------------------------------------------------------------- /libs/ui/hooks/focus-trap/index.ts: -------------------------------------------------------------------------------- 1 | export { useFocusReturnToLast } from './useFocusReturnToLast'; 2 | -------------------------------------------------------------------------------- /libs/ui/lib/theme.ts: -------------------------------------------------------------------------------- 1 | export const getColorVariable = (color: string) => `var(--palette-${color})`; 2 | -------------------------------------------------------------------------------- /.yarn/install-state.gz: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/secundant/ts-monorepo-template/HEAD/.yarn/install-state.gz -------------------------------------------------------------------------------- /libs/ui/types/index.ts: -------------------------------------------------------------------------------- 1 | export * from './common'; 2 | export * from './elements'; 3 | export * from './theme'; 4 | -------------------------------------------------------------------------------- /apps/todo-web/pages/todos.tsx: -------------------------------------------------------------------------------- 1 | import { TodosScreen } from '@/screens/todos'; 2 | 3 | export default TodosScreen; 4 | -------------------------------------------------------------------------------- /libs/ui/core/button/index.ts: -------------------------------------------------------------------------------- 1 | export { Button } from './button'; 2 | 3 | export type { ButtonProps } from './button'; 4 | -------------------------------------------------------------------------------- /libs/ui/core/transition/index.ts: -------------------------------------------------------------------------------- 1 | export { Transition } from './transition'; 2 | export { useTransition } from './useTransition'; 3 | -------------------------------------------------------------------------------- /apps/todo-web/entities/task/index.ts: -------------------------------------------------------------------------------- 1 | import * as TaskModel from './model'; 2 | 3 | export * from './ui'; 4 | export { TaskModel }; 5 | -------------------------------------------------------------------------------- /_templates/ws/new/readme.ejs.t: -------------------------------------------------------------------------------- 1 | --- 2 | to: <%=type%>/<%=name%>/readme.md 3 | --- 4 | # @<%=type%>/<%=name%> 5 | 6 | TODO Add description 7 | -------------------------------------------------------------------------------- /libs/ui/core/svg-icon/index.ts: -------------------------------------------------------------------------------- 1 | export { SvgIcon, createSvgIcon } from './svg-icon'; 2 | 3 | export type { SvgIconProps } from './svg-icon'; 4 | -------------------------------------------------------------------------------- /apps/client-web/postcss.config.js: -------------------------------------------------------------------------------- 1 | const { getPostCSSConfig } = require('@libs/ui'); 2 | 3 | module.exports = getPostCSSConfig({ cwd: __dirname }); 4 | -------------------------------------------------------------------------------- /apps/todo-web/postcss.config.js: -------------------------------------------------------------------------------- 1 | const { getPostCSSConfig } = require('@libs/ui'); 2 | 3 | module.exports = getPostCSSConfig({ cwd: __dirname }); 4 | -------------------------------------------------------------------------------- /apps/todo-web/tailwind.config.js: -------------------------------------------------------------------------------- 1 | const { getTailwindConfig } = require('@libs/ui'); 2 | 3 | module.exports = getTailwindConfig({ cwd: __dirname }); 4 | -------------------------------------------------------------------------------- /_templates/ui/new/prompt.js: -------------------------------------------------------------------------------- 1 | module.exports = [ 2 | { 3 | type: 'input', 4 | name: 'name', 5 | message: 'Name of component' 6 | } 7 | ]; 8 | -------------------------------------------------------------------------------- /apps/client-web/tailwind.config.js: -------------------------------------------------------------------------------- 1 | const { getTailwindConfig } = require('@libs/ui'); 2 | 3 | module.exports = getTailwindConfig({ cwd: __dirname }); 4 | -------------------------------------------------------------------------------- /libs/ui/types/global.d.ts: -------------------------------------------------------------------------------- 1 | declare module '*.module.css' { 2 | const classes: { readonly [key: string]: string }; 3 | export default classes; 4 | } 5 | -------------------------------------------------------------------------------- /libs/ui/core/typography/index.ts: -------------------------------------------------------------------------------- 1 | // Components 2 | export { Typography } from './typography'; 3 | 4 | // Types 5 | export type { TypographyProps } from './typography'; 6 | -------------------------------------------------------------------------------- /apps/todo-web/pages/404.tsx: -------------------------------------------------------------------------------- 1 | import React, { ReactElement } from 'react'; 2 | 3 | export default function Error404(): ReactElement { 4 | return
Press Cmd+L for exit
33 | 34 |