cal.pub0.org/packages/app-store-cli
sean-brydon 277b0c4c92
Feat/design system (#3051)
* Storybook Boilerplate setup

* Inital Setup

* First story

* Color Design System

* Badge Story + Comp

* Checkbox UI + Stories

* Update Red colors + Button Group

* Switch+Stories / Default brand color

* Update Version + Button Group combined

* Compact Butotn Group

* Tidy up Selectors

* Adds Tooltip to Button

* TextInput

* Update SB

* Prefix Input

* Match text area styles

* Prefix Controls

* Update spacing on text area

* Text Input Suffix

* Color Picker

* Update storybook

* Icon Suffix/Prefix

* Datepicker + move components to monorepo

* Text color on labels

* Move Radio over to monorepo

* Move CustomBranding to calcom/ib

* Radio

* IconBadge Component

* Update radio indicator background

* Disabled radio state

* Delete yarn.lock

* Revert "Delete yarn.lock"

This reverts commit 9b99d244b7.

* Fix webhook test

* Replace old toast location

* Update radio path

* Empty State

* Update Badge.tsx

* Update Badge.tsx

* Banner Component+story

* Creation Modal

* Creation Dialog updated

* Button hover dialog

* Confirmation Modal

* Datepicker (Booking)

* PageHeader

* Fix border width

* PageHeader update search bar

* Fix input height

* Fix button group size

* Add spacing between badges - font smoothing

* Update button position on banner

* Banner update

* Fixing focus state on suffix/prefix inputs

* Implement A11y addon

* Add aria label

* error && "text-red-800"

* Fix button hover

* Change colors

* Generate snapshot tests for on hover button

* Revert colors to demo

* Change colors

* Fix Linear Issues

* Form Stepper component

* Add padding back to input

* Move ui to UI_V2

* Use V2

* Update imports for v1

* Update imports for v1

* Upgrade to nextjs in storybook root

* Update website submodule

* Avatar Groups

* Fix webpack again

* Vertical Tab Item

[WIP] - active state on small item is not working currently

* Vertical Tab Group

* Add Github action

* Fix website submodule

* Fix GH action

* Rename Workflow

* Adds lint report for CI

* Lint report fixes

* NavigationItem comments

* VerticalTabItem type fixes

* Fix avatar blur

* Fix comments

* Adding isEmbed to window object

* Disable components that use router mock.

* Load inter via google fonts

* Started select

* Adding base Breadcrumb

* Update readme

* Formatting

* Fixes

* Dependencies matching

* Linting

* Update FormStep.stories.tsx

* Linting

* Update MultiSelectCheckboxes.tsx

Co-authored-by: zomars <zomars@me.com>
Co-authored-by: Peer Richelsen <peeroke@gmail.com>
2022-07-22 18:39:50 -06:00
..
src Use nodeJS 14+ compatible method for replacing (#3429) 2022-07-19 18:24:19 +05:30
.gitignore [Feature] App Store CLI - Make it super easy to add an app. (#2917) 2022-06-07 11:43:32 +05:30
package.json Feat/design system (#3051) 2022-07-22 18:39:50 -06:00
readme.md Runs format script 2022-06-24 07:37:56 -06:00
tsconfig.json [Feature] App Store CLI - Make it super easy to add an app. (#2917) 2022-06-07 11:43:32 +05:30

readme.md

Steps to create an app

  • Create a folder in packages/app-store/{APP_NAME} = {APP}
  • Fill it with a sample app
    • Modify {APP}/_metadata.ts with the data provided

Approach

  • appType is derived from App Name(a slugify operation that makes a string that can be used as a director name, a variable name for imports and a URL path).
  • appType is then used to create the app directory. It becomes config.type of config.json. config.type is the value used to create an entry in App table and retrieve any apps or credentials. It also becomes App.dirName
  • dirnames that don't start with _ are considered apps in packages/app-store and based on those apps .generated.ts* files are created. This allows pre-cli apps to keep on working.
  • app directory is populated with app-store/_baseApp with newly updated config.json and package.json
  • packages/prisma/seed-app-store.config.json is updated with new app.

NOTE: After app-store-cli is live, Credential.appId and Credential.type would be same for new apps. For old apps they would remain different. Credential.type would be used to identify credentials in integrations call and Credential.appId/App.slug would be used to identify apps. If we rename all existing apps to their slug names, we can remove type and then use just appId to refer to things everywhere. This can be done later on.

TODO

  • Beta Release
    • Show a warning somewhere that app directory must not be renamed manually, edit command must be used.
    • edit command should ask for slug and verify if it exists
  • Improvements
    • Prefill fields in edit command
    • Merge app-store:watch and app-store commands, introduce app-store --watch
    • Allow inputs in non interactive way as well - That would allow easily copy pasting commands.
    • App already exists check. Ask user to run edit/regenerate command
    • An app created through CLI should be able to completely skip API validation for testing purposes. Credentials should be created with no API specified specific to the app. It would allow us to test any app end to end not worrying about the corresponding API endpoint.
    • Require assets path relative to app dir.

Roadmap

  • Avoid delete and edit on apps created outside of cli
  • Someone can add wrong directory name(which doesn't satisfy slug requirements) manually. How to handle it.
  • Allow editing and updating app from the cal app itself - including assets uploading when developing locally.
  • Improvements in shared code across app
    • Use baseApp/api/add.ts for all apps with configuration of credentials creation and redirection URL.
  • Delete creation side effects if App creation fails - Might make debugging difficult
    • This is so that web app doesn't break because of additional app folders or faulty db-seed