Commit Graph

25 Commits

Author SHA1 Message Date
Bruno Quaresma f3083226ab
chore: add package manager (#12551)
Every time I run `pnpm` in the project it adds the package manager attribute on package.json so I just decided to push it since it does not look like an issue and we can make sure everyone is running the same pnpm version.
2024-03-12 10:44:23 -03:00
Kayla Washburn-Love 0fe109d517
chore: sort imports in our typescript code (#12417) 2024-03-05 16:31:22 -07:00
Kayla Washburn 619df23ad1
chore: fix linting issues and generated files (#10317) 2023-10-17 14:41:35 -06:00
sharkymark 4bed492012
docs: ui option for adding licenses (#9322) 2023-08-24 22:23:59 -05:00
Kyle Carberry 7404ee9b21
chore: add name to top-level package.json to allow importing (#9209) 2023-08-20 00:35:38 +00:00
Kyle Carberry 4d85d56327
chore: add version to top-level package.json to allow importing (#9208) 2023-08-20 00:10:53 +00:00
Colin Adler 4b81cfaa0d
chore: switch from `yarn` to `pnpm` (#8822) 2023-08-02 13:28:16 -05:00
Bryan 78e652a268
refactor: Move package.json and other front-end collateral into 'site' (#128)
This refactors the front-end collateral to all live within `site` - so no `package.json` at the root.

The reason we had this initially is that the jest test run and NextJS actually require having _two_ different `tsconfig`s - Next needs `jsx:"preserve"`, while jest needs `jsx:"react"` - we were using `tsconfig`s at different levels at the hierarchy to manage this.

I changed this behavior to still use two different `tsconfig.json`s, which is mandatory - but just side-by-side in `site`.

Once that's fixed, it was easy to move everything into `site`

Follow up from: https://github.com/coder/coder/pull/118#discussion_r796244577
2022-02-01 13:34:43 -08:00
dependabot[bot] b586a35c6d
chore: bump http-proxy-middleware from 2.0.1 to 2.0.2 (#115)
Bumps [http-proxy-middleware](https://github.com/chimurai/http-proxy-middleware) from 2.0.1 to 2.0.2.
- [Release notes](https://github.com/chimurai/http-proxy-middleware/releases)
- [Changelog](https://github.com/chimurai/http-proxy-middleware/blob/master/CHANGELOG.md)
- [Commits](https://github.com/chimurai/http-proxy-middleware/compare/v2.0.1...v2.0.2)

---
updated-dependencies:
- dependency-name: http-proxy-middleware
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2022-01-31 09:53:27 -08:00
dependabot[bot] 89fad40c42
chore: bump typescript from 4.5.4 to 4.5.5 (#114)
Bumps [typescript](https://github.com/Microsoft/TypeScript) from 4.5.4 to 4.5.5.
- [Release notes](https://github.com/Microsoft/TypeScript/releases)
- [Commits](https://github.com/Microsoft/TypeScript/compare/v4.5.4...v4.5.5)

---
updated-dependencies:
- dependency-name: typescript
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2022-01-31 09:33:48 -08:00
dependabot[bot] 1f7003843d
chore: bump ts-jest from 27.1.2 to 27.1.3 (#111)
Bumps [ts-jest](https://github.com/kulshekhar/ts-jest) from 27.1.2 to 27.1.3.
- [Release notes](https://github.com/kulshekhar/ts-jest/releases)
- [Changelog](https://github.com/kulshekhar/ts-jest/blob/main/CHANGELOG.md)
- [Commits](https://github.com/kulshekhar/ts-jest/compare/v27.1.2...v27.1.3)

---
updated-dependencies:
- dependency-name: ts-jest
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2022-01-31 09:32:53 -08:00
dependabot[bot] 8560db9272
chore: bump @types/superagent from 4.1.14 to 4.1.15 (#110)
Bumps [@types/superagent](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/superagent) from 4.1.14 to 4.1.15.
- [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases)
- [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/superagent)

---
updated-dependencies:
- dependency-name: "@types/superagent"
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2022-01-31 09:08:34 -08:00
dependabot[bot] dae55a4ad6
chore: bump @types/node from 14.18.4 to 14.18.9 (#106)
Bumps [@types/node](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/node) from 14.18.4 to 14.18.9.
- [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases)
- [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/node)

---
updated-dependencies:
- dependency-name: "@types/node"
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2022-01-31 09:06:32 -08:00
dependabot[bot] c5e8259180
chore: bump eslint-plugin-jest from 25.7.0 to 26.0.0 (#104)
Bumps [eslint-plugin-jest](https://github.com/jest-community/eslint-plugin-jest) from 25.7.0 to 26.0.0.
- [Release notes](https://github.com/jest-community/eslint-plugin-jest/releases)
- [Changelog](https://github.com/jest-community/eslint-plugin-jest/blob/main/CHANGELOG.md)
- [Commits](https://github.com/jest-community/eslint-plugin-jest/compare/v25.7.0...v26.0.0)

---
updated-dependencies:
- dependency-name: eslint-plugin-jest
  dependency-type: direct:development
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2022-01-31 09:06:17 -08:00
Kyle Carberry e79817399e
Revert "chore: bump @material-ui/core from 4.9.4 to 4.12.3 (#102)" (#113)
This reverts commit d65ce2df71.
2022-01-31 09:24:13 -06:00
dependabot[bot] 0f30d856da
chore: bump swr from 1.1.2 to 1.2.0 (#103) 2022-01-31 04:28:18 +00:00
dependabot[bot] d65ce2df71
chore: bump @material-ui/core from 4.9.4 to 4.12.3 (#102) 2022-01-31 04:23:41 +00:00
dependabot[bot] a193a089b8
chore: Bump next from 12.0.7 to 12.0.9 (#79)
Bumps [next](https://github.com/vercel/next.js) from 12.0.7 to 12.0.9.
- [Release notes](https://github.com/vercel/next.js/releases)
- [Changelog](https://github.com/vercel/next.js/blob/canary/release.js)
- [Commits](https://github.com/vercel/next.js/compare/v12.0.7...v12.0.9)

---
updated-dependencies:
- dependency-name: next
  dependency-type: direct:development
...

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2022-01-28 17:39:04 -08:00
Bryan 4183a4e01c
feat: Initial Login flow (#42)
This just implements a basic sign-in flow, using the new endpoints in #29 :
![2022-01-20 12 35 30](https://user-images.githubusercontent.com/88213859/150418044-85900d1f-8890-4c60-baae-234342de71fa.gif)

This brings over several dependencies that are necessary:
- `formik`
- `yep`

Ports over some v1 code to bootstrap it:
- `FormTextField`
- `PasswordField`
- `CoderIcon`

And implements basic sign-in:
Fixes #37 
Fixes #43

This does not implement it navbar integration (importantly - there is no way to sign out yet, unless you manually delete your `session_token`). I'll do that in the next PR - figured this was big enough to get reviewed.
2022-01-21 11:34:26 -08:00
Bryan 7b9347bce6
chore: Add linter for typescript code (#45)
- Add and configure `eslint`
- Add to build pipeline
- Fix lint failures
2022-01-20 22:00:14 -08:00
Kyle Carberry 6a919aea79
feat: Add authentication and personal user endpoint (#29)
* feat: Add authentication and personal user endpoint

This contribution adds a lot of scaffolding for the database fake
and testability of coderd.

A new endpoint "/user" is added to return the currently authenticated
user to the requester.

* Use TestMain to catch leak instead

* Add userpassword package

* Add WIP

* Add user auth

* Fix test

* Add comments

* Fix login response

* Fix order

* Fix generated code

* Update httpapi/httpapi.go

Co-authored-by: Bryan <bryan@coder.com>

Co-authored-by: Bryan <bryan@coder.com>
2022-01-20 13:46:51 +00:00
Bryan 4dc6e35c24
feat: Bundle UI into coderd; add ./develop.sh script (#28)
This change bundles the static assets like we have for v1 - using the [`embed`](https://pkg.go.dev/embed) go package. Fixes #22 

In addition, it sets up a development script that runs `coderd` locally and serves the front-end, with hot-reloading. The script used is `./develop.sh`:

![2022-01-14 17 30 14](https://user-images.githubusercontent.com/88213859/149603926-f673d3d3-ba12-4eda-bcdd-427252405480.gif)

> NOTE: The UI is still placeholder, of course. Need to start testing out a simple, placeholder flow for the new v2 world as a next step

Summary of changes:
- Add build steps for `go` in the `Makefile`
  - Add a step for production build, in which we use the `embed` tag
  - Add a step for development, which doesn't need the `embed` tag - so we don't need to build the front-end twice
- Add `next export` build step to output front-end artifacts in `out`
- Add a `site` package for `go`
  - Add `embed_static.go` and `embed.go`. This is mostly brought in as-is from v1, except removing some intercom/sentry CSP entries that we aren't using.
- Add a [next development server](https://nextjs.org/docs/advanced-features/custom-server)
- Add a `v2-dev` script, that runs `coderd` and the `next` dev server side-by-side
- Use the `site` package as the fallback handler.
- Add `.gitignore` entries for additional build collateral
2022-01-18 13:13:19 -08:00
Bryan 423611b001
chore: Add initial jest tests + code coverage (#13)
- Adds initial infra for running front-end tests (`jest`, `ts-jest`, `jest.config.js`, etc)
- Adds codecov integration front-end code
2022-01-13 18:48:23 -08:00
Bryan ace89161fb
feat(cdr): Initial UI scaffolding
This is testing out [Approach 3](https://www.notion.so/coderhq/Workspaces-v2-Initial-UI-Scaffolding-3b07d2847eed48839a7e6f0f2bb9bf56#56256f25d2954897a8ee315f0820cedd) in the UI scaffolding RFC.

Fixes https://github.com/coder/coder/issues/11

The folder structure looks like:
- `site`
    - `components` (buttons, empty state, etc)
    - `pages` (large sections of UI -> composition of components)
    - `theme` (files defining our palette)

Several components were able to be brought in essentially unmodified:
- `SplitButton`
- `EmptyState`
- `Footer`
-  All the icons / logos
- Theming (removed several items that aren't necessary, yet, though)

Other components had more coupling, and need more refactoring:
- `NavBar`
- `Confetti`

Current State:

![2022-01-06 17 16 31](https://user-images.githubusercontent.com/88213859/148475521-96e080cc-1d33-4b8e-a434-29e388936e3f.gif)

For a full working app, there's potentially a lot more to bring in:
- User / Account Settings Stuff
- Users Page
- Organizations Page
(and all the supporting dependencies)
2022-01-12 14:25:12 -08:00
Bryan 78973eaf3f
chore: Initial GHA workflow (#1)
This implements an initial GitHub Actions workflow for us - to be run on PRs and on `main` commits.

This just implements a really simple `style/fmt` check - running `prettier` on the `README.md`.

I assumed we'll stick with using a top-level `Makefile` for commands like in `m` and `link` - but open to alternatives, too!

Since I was adding a `package.json` and `node_modules` for this, I realized we were missing `.gitignore`s, so I added some a subset of the ignore files from `coder/m`
2022-01-03 18:54:27 -08:00