Skip to content

Commit

Permalink
Merge branch 'feature/major-refactor' into dev
Browse files Browse the repository at this point in the history
  • Loading branch information
nathandf committed Jun 25, 2024
2 parents 9d80526 + 50ca95d commit 1f99fe4
Show file tree
Hide file tree
Showing 1,082 changed files with 67,341 additions and 41,113 deletions.
4 changes: 3 additions & 1 deletion .eslintignore
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,6 @@ node_modules
coverage
build
webpack.*.js
*.test.js
*.test.js
dist
*.js
2 changes: 0 additions & 2 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
@@ -1,13 +1,11 @@
name: CI

# Controls when the action will run. Triggers the workflow on pushes to main or on pull request events
on:
push:
branches: [dev, staging, test, release-**]
pull_request:
branches: [dev, staging, test, release-**]

# A workflow run is made up of one or more jobs that can run sequentially or in parallel
jobs:
Client_Side_Unit_Tests:
runs-on: ubuntu-20.04
Expand Down
3 changes: 2 additions & 1 deletion .prettierignore
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,5 @@ node_modules
coverage
build
webpack.*.js
*.test.js
*.test.js
dist
2 changes: 1 addition & 1 deletion Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM node:16.19
FROM node:22

RUN mkdir tapisui
RUN mkdir tapisui/src
Expand Down
53 changes: 15 additions & 38 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,46 +1,23 @@
# Getting Started with Create React App
# Getting Started with TapisUI

This project was bootstrapped with [Create React App](https://github.com/facebook/create-react-app).
1. Clone the TapisUI repository
2. `cd` into projects root directory
3. Run `npm run init-project`. This will build and install all of the libraries and external packages. At the end of this process, the vite library will start a local install of TapisUI at **http://localhost:3000**

## Available Scripts
# Starting TapisUI

In the project directory, you can run:
From the root directory of the project, run `npm run start`

### `npm start`
# TapisUI supporting packages

Runs the app in the development mode.\
Open [http://localhost:3000](http://localhost:3000) to view it in the browser.
Much of the functionality and components used in TapisUI exist as their own NPM packages.
This enables developers to use TapisUI features and ui in their own projects. These packages are located in the `lib` directory in the root of TapisUI. There are 4 main packages.

The page will reload if you make edits.\
You will also see any lint errors in the console.
- **tapsiui-extensions-core** - A library for building extensions and plugins to TapisUI
- **tapisui-common** - This package contains the generic components used in TapisUI as well as components specific to core Tapis services. These Tapis-specific components fetch data from Tapis services and render useful UI such as a file navigator for Tapis Systems, the Tapis Job Launcher Wizard, and more.
- **tapisui-api** - A package of function that make API calls directly to Tapis services
- **tapisui-hooks** - A package of hooks that use the **tapisui-api** library to fetch and mutate data as well as handle errors generated during API calls. With these hooks, developers can tie UI into the lifecycle of an API request via properties such as `isLoading`, `isSuccess`, `isError`, and more.

### `npm test`
## Updating supporting packages

Launches the test runner in the interactive watch mode.\
See the section about [running tests](https://facebook.github.io/create-react-app/docs/running-tests) for more information.

### `npm run build`

Builds the app for production to the `build` folder.\
It correctly bundles React in production mode and optimizes the build for the best performance.

The build is minified and the filenames include the hashes.\
Your app is ready to be deployed!

See the section about [deployment](https://facebook.github.io/create-react-app/docs/deployment) for more information.

### `npm run eject`

**Note: this is a one-way operation. Once you `eject`, you can’t go back!**

If you aren’t satisfied with the build tool and configuration choices, you can `eject` at any time. This command will remove the single build dependency from your project.

Instead, it will copy all the configuration files and the transitive dependencies (webpack, Babel, ESLint, etc) right into your project so you have full control over them. All of the commands except `eject` will still work, but they will point to the copied scripts so you can tweak them. At this point you’re on your own.

You don’t have to ever use `eject`. The curated feature set is suitable for small and middle deployments, and you shouldn’t feel obligated to use this feature. However we understand that this tool wouldn’t be useful if you couldn’t customize it when you are ready for it.

## Learn More

You can learn more in the [Create React App documentation](https://facebook.github.io/create-react-app/docs/getting-started).

To learn React, check out the [React documentation](https://reactjs.org/).
# Extensions
2 changes: 1 addition & 1 deletion __mocks__/styleMock.js
Original file line number Diff line number Diff line change
@@ -1 +1 @@
module.exports = {};
module.exports = 'test-file-stub';
14 changes: 3 additions & 11 deletions public/index.html → index.html
Original file line number Diff line number Diff line change
Expand Up @@ -12,17 +12,8 @@
manifest.json provides metadata used when your web app is installed on a
user's mobile device or desktop. See https://developers.google.com/web/fundamentals/web-app-manifest/
-->
<link rel="manifest" href="%PUBLIC_URL%/manifest.json" />
<!--
Notice the use of %PUBLIC_URL% in the tags above.
It will be replaced with the URL of the `public` folder during the build.
Only files inside the `public` folder can be referenced from the HTML.
Unlike "/favicon.ico" or "favicon.ico", "%PUBLIC_URL%/favicon.ico" will
work correctly both with client-side routing and a non-root public URL.
Learn how to configure a non-root public URL by running `npm run build`.
-->
<script src="https://cdn.jsdelivr.net/npm/[email protected]/dist/ponyfill.min.js"></script>
<link rel="manifest" href="/manifest.json" />
<!-- <script src="https://cdn.jsdelivr.net/npm/[email protected]/dist/ponyfill.min.js"></script> -->
<title>Tapis UI</title>
</head>
<body>
Expand All @@ -38,5 +29,6 @@
To begin the development, run `npm start` or `yarn start`.
To create a production bundle, use `npm run build` or `yarn build`.
-->
<script type="module" src="/src/index.tsx"></script>
</body>
</html>
2 changes: 2 additions & 0 deletions lib/icicle-tapisui-extension/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
dist
node_modules
3 changes: 3 additions & 0 deletions lib/icicle-tapisui-extension/.npmignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
node_modules
bundle.ts
tasks.ts
1 change: 1 addition & 0 deletions lib/icicle-tapisui-extension/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
# tapisui-extension-icicle
179 changes: 179 additions & 0 deletions lib/icicle-tapisui-extension/package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

44 changes: 44 additions & 0 deletions lib/icicle-tapisui-extension/package.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,44 @@
{
"name": "@icicle/tapisui-extension",
"version": "0.1.1",
"description": "TapisUI extension configuration for ICICLE",
"main": "./dist/index.js",
"typings": "./dist/index.d.ts",
"types": "./dist/index.d.ts",
"scripts": {
"test": "echo \"Error: no test specified\" && exit 1",
"push": "npm run build && npm publish --access public",
"build": "npx ts-node src/bundle.ts && npx tsc"
},
"repository": {
"type": "git",
"url": "git+https://github.com/ICICLE-ai/tapisui-extension-icicle.git"
},
"keywords": [
"typescript",
"tapisui",
"UT",
"TACC",
"CIC"
],
"author": "Nathan Freeman",
"collaborators": [
{
"name": "Christian Garcia"
}
],
"license": "ISC",
"bugs": {
"url": "https://github.com/ICICLE-ai/tapisui-extension-icicle/issues"
},
"homepage": "https://github.com/ICICLE-ai/tapisui-extension-icicle#readme",
"dependencies": {
"@tapis/tapis-typescript": "^0.0.29",
"@tapis/tapisui-extensions-core": "file:../tapisui-extensions-core",
"react": "^18.3.1"
},
"devDependencies": {
"@types/node": "^18.19.33",
"typescript": "^4.9.5"
}
}
4 changes: 4 additions & 0 deletions lib/icicle-tapisui-extension/src/bundle.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
import { bundleTasks } from '@tapis/tapisui-extensions-core';
import { tasks } from './tasks';

bundleTasks(tasks, __dirname + '/gen/');
7 changes: 7 additions & 0 deletions lib/icicle-tapisui-extension/src/gen/index.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
import { Workflows } from '@tapis/tapis-typescript';
import { task as task0 } from './test-function';
import { task as task1 } from './test-function-2';
export const tasks: Array<Workflows.Task> = [
Workflows.FunctionTaskFromJSON(task0),
Workflows.FunctionTaskFromJSON(task1),
];
Loading

0 comments on commit 1f99fe4

Please sign in to comment.