Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
19 commits
Select commit Hold shift + click to select a range
ee3d116
Merge pull request #5605 from cloudforet-io/master
piggggggggy Jan 23, 2025
919a464
build(deps-dev): bump vite from 4.5.3 to 4.5.6
dependabot[bot] Jan 23, 2025
5bebb42
build: update package-lock.json
WANZARGEN Jan 23, 2025
05e1d12
refactor: create mrinae-foundation package for separation of concerns
sulmoJ Jan 20, 2025
d7f47d1
refactor: create storybook-config-custom package for separation of co…
sulmoJ Jan 20, 2025
54e3cda
feat(web-storybook): create storybook setup
sulmoJ Jan 20, 2025
c55d75b
refactor: move tailwindcss dependency from postcss-config-custom to m…
sulmoJ Jan 21, 2025
438d033
refactor(storybook): update theme configuration and dependencies
sulmoJ Jan 23, 2025
d5a30fa
feat(web-storybook): update dev server port to 6007
sulmoJ Jan 23, 2025
af4af3f
Merge pull request #5570 from sulmoJ/develop
sulmoJ Jan 23, 2025
7bfb1fc
Merge remote-tracking branch 'cloudforet-io/master' into develop
piggggggggy Jan 24, 2025
4afa6a5
chore: version 2.0.dev305
admin-cloudforet Jan 24, 2025
a20267b
Merge branch 'master' into develop
skdud4659 Jan 24, 2025
d80dbb7
refactor: pcollapsiblepanel logic (#5612)
kkdy21 Feb 3, 2025
b9b7959
build: update turbo to version 2.3.4 (#5609)
sulmoJ Feb 3, 2025
2e9aba0
feat: create unified-storybook app (#5610)
sulmoJ Feb 3, 2025
d16ab94
test: workflow dispatch test
kkdy21 Feb 4, 2025
2abbcaa
Revert "test: workflow dispatch test"
kkdy21 Feb 4, 2025
ca96f09
chore: create workflows merge from master to develop and check commit…
kkdy21 Feb 4, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 3 additions & 2 deletions .dockerignore
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,8 @@ deploy
# Output
out
**/dist
apps/storybook/.out
apps/mirinae-storybook/.out
apps/web-storybook/.out
packages/mirinae/css
packages/mirinae/types

Expand Down Expand Up @@ -55,4 +56,4 @@ VERSION
.idea
*.swp
*.bak
**/.DS_Store
**/.DS_Store
65 changes: 65 additions & 0 deletions .github/workflows/dispatch_master_to_develop.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,65 @@
name: "[Dispatch] Master To Develop"

on:
workflow_dispatch:
inputs:
version:
description: 'enter version(x.y.z)'
required: true
default: '2.0.0'

env:
VERSION: ${{ github.event.inputs.version }}
SLACK_WEBHOOK_URL: ${{ secrets.SLACK_WEBHOOK_URL }}
REF_BRANCH: "master"

jobs:
merge_to_develop:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
with:
ref: ${{env.REF_BRANCH}}
fetch-depth: 0
fetch-tags: false
submodules: true
token: ${{ secrets.PAT_TOKEN }}

- name: Fetch develop branch
run: |
git checkout -b develop origin/develop

- name: Configure git
run: |
git log -n 10 --oneline
git branch
git config --global user.email "${{ vars.GIT_EMAIL }}"
git config --global user.name "${{ vars.GIT_USERNAME }}"

- name: Import GPG key
id: import-gpg
uses: crazy-max/ghaction-import-gpg@v6.2.0
with:
gpg_private_key: ${{ secrets.GPG_PRIVATE_KEY }}
passphrase: ${{ secrets.GPG_PASSPHRASE }}
git_user_signingkey: true
git_commit_gpgsign: true

- name: Merge master into develop
run: |
git merge --no-ff master -m "chore: merge master into develop after ${{ env.VERSION }} version tagging"

- name: Push changes to develop using GitHub push action
uses: ad-m/github-push-action@v0.6.0
with:
branch: develop
github_token: ${{ secrets.PAT_TOKEN }}

- name: Notice when job fails
if: failure()
uses: 8398a7/action-slack@v3.15.0
with:
status: ${{job.status}}
fields: repo,workflow,job
author_name: Github Action Slack
37 changes: 36 additions & 1 deletion .github/workflows/dispatch_release.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -20,10 +20,29 @@ env:
ARCH: ${{ github.event.inputs.container_arch }}
VERSION: ${{ github.event.inputs.version }}
SLACK_WEBHOOK_URL: ${{ secrets.SLACK_WEBHOOK_URL }}
REF_BRANCH: "master"

jobs:
check-branch:
runs-on: ubuntu-latest
steps:
- name: Check branch with regex
run: |
if [[ ! "${{ github.ref }}" =~ ^refs/heads/(${{env.REF_BRANCH}}.*|.*${{env.REF_BRANCH}})$ ]]; then
echo `::error::Branch should always be run from '${{env.REF_BRANCH}}', Running branch: ${github.ref_name}`.
exit 1
fi
- name: Notice when job fails
if: failure()
uses: 8398a7/action-slack@v3.15.0
with:
status: ${{job.status}}
fields: repo,workflow,job
author_name: Github Action Slack

mirinae:
runs-on: ubuntu-latest
needs: check-branch
steps:
- name: Invoke mirinae release workflow
id: mirinae
Expand Down Expand Up @@ -63,6 +82,7 @@ jobs:
uses: actions/checkout@v3
with:
submodules: true
ref: ${{ env.REF_BRANCH }}
token: ${{ secrets.PAT_TOKEN }}

- name: Setup Node.js
Expand Down Expand Up @@ -91,7 +111,7 @@ jobs:

- name: Import GPG key
id: import-gpg
uses: crazy-max/ghaction-import-gpg@v6.2.0
uses: crazy-max/ghaction-import-gpg@v6.2.0
with:
gpg_private_key: ${{ secrets.GPG_PRIVATE_KEY }}
passphrase: ${{ secrets.GPG_PASSPHRASE }}
Expand Down Expand Up @@ -129,6 +149,21 @@ jobs:
github_token: ${{ secrets.PAT_TOKEN }}
branch: ${{ github.ref }}

- name: Trigger dispatch_master_to_develop.yaml workflow
uses: actions/github-script@v6
with:
github-token: ${{ secrets.PAT_TOKEN }}
script: |
github.rest.actions.createWorkflowDispatch({
owner: "${{ github.repository_owner }}",
repo: "${{ github.event.repository.name }}",
workflow_id: "dispatch_master_to_develop.yaml",
inputs: {
version: "${{ github.event.inputs.version }}",
},
ref: "${{env.REF_BRANCH}}",
});

- name: Set up QEMU
uses: docker/setup-qemu-action@v2

Expand Down
52 changes: 52 additions & 0 deletions .github/workflows/pull_request_check_revert_candidate_commits.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,52 @@
name: "[Pull Request] Check Revert Candidate Commits"

on:
pull_request:
branches: [master]

jobs:
check-commits:
runs-on: ubuntu-latest
steps:
- name: Find feat(backend) commits
id: check-commits
env:
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: |
COMMITS=$(gh api repos/${{ github.repository }}/pulls/${{ github.event.pull_request.number }}/commits \
--jq '.[] | select(.commit.message | test("^feat\\(backend")) | .sha + " " + .commit.message')

if [ -z "$COMMITS" ]; then
echo "No matching commits found"
echo "found=false" >> $GITHUB_OUTPUT
else
echo "Found matching commits"
echo "found=true" >> $GITHUB_OUTPUT
COMMITS="${COMMITS//$'\n'/'%0A'}"
echo "commits=$COMMITS" >> $GITHUB_OUTPUT
fi

- name: Comment feat(backend) commits
if: steps.check-commits.outputs.found == 'true'
uses: actions/github-script@v6
with:
script: |
const prNumber = context.payload.pull_request.number;
const commits = `${{ steps.check-commits.outputs.commits }}`.replace(/%0A/g, '\n');
await github.rest.issues.createComment({
...context.repo,
issue_number: prNumber,
body: `⚠️ The following commits require review:\n\n${commits}`
});

- name: Comment no feat(backend) commits
if: steps.check-commits.outputs.found == 'false'
uses: actions/github-script@v6
with:
script: |
await github.rest.issues.createComment({
...context.repo,
issue_number: context.payload.pull_request.number,
body: `✅ There are no commits in this PR that require review.`
});

File renamed without changes.
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
@@ -1,6 +1,4 @@
import { create } from '@storybook/theming/create';

export default create({
export default {
base: 'light',
colorPrimary: '#6638B6',
colorSecondary: 'rgba(102, 56, 182, 0.9)',
Expand Down Expand Up @@ -29,4 +27,4 @@ export default create({
brandTitle: 'Mirinae Design System',
brandUrl: 'https://github.com/cloudforet-io/mirinae',
brandImage: './images/SpaceONE_logoTypeA.svg',
});
};
13 changes: 13 additions & 0 deletions apps/mirinae-storybook/.storybook/main.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
import type { StorybookConfig } from "@storybook/vue-vite";
import { mainConfig } from "storybook-config-custom";

/** @type { import('@storybook/vue-vite').StorybookConfig } */
const config: StorybookConfig = {
...mainConfig,
stories: [
'../../../packages/mirinae/src/**/*.mdx',
'../../../packages/mirinae/src/**/*.stories.@(js|jsx|ts|tsx)',
],
};

export default config;
9 changes: 9 additions & 0 deletions apps/mirinae-storybook/.storybook/manager.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@

import CloudforetThemeVar from './CloudforetTheme';
import { setConfig } from 'storybook-config-custom';

// window.STORYBOOK_GA_ID = 'UA-159327743-4';

setConfig({
theme: CloudforetThemeVar,
})
Original file line number Diff line number Diff line change
Expand Up @@ -12,10 +12,12 @@ import VueRouter from 'vue-router';
import SvgIcon from 'vue-svgicon';
import webFontLoader from 'webfontloader';

import screens from '@/styles/screens.cjs';
import { fontUrls, webFonts } from '@/styles/web-fonts.cjs';
import screens from 'mirinae-foundation/screens.cjs';

import SpaceOneTheme from './CloudforetTheme';
import { fontUrls, webFonts } from 'mirinae-foundation/web-fonts.cjs';

import CloudforetTheme from './CloudforetTheme';
import { createTheme } from 'storybook-config-custom';

Vue.use(VueRouter);
Vue.use(VueI18n);
Expand Down Expand Up @@ -63,7 +65,7 @@ const preview = {
}
return null;
},
theme: SpaceOneTheme,
theme: createTheme(CloudforetTheme),
},
viewport: {
viewports,
Expand Down
20 changes: 20 additions & 0 deletions apps/mirinae-storybook/package.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
{
"name": "mirinae-storybook",
"version": "1.0.0",
"description": "",
"main": "index.js",
"scripts": {
"dev": "storybook dev -p 6006",
"build": "storybook build"
},
"keywords": [],
"author": "",
"license": "ISC",
"devDependencies": {
"eslint-config-custom": "*",
"mirinae-foundation": "*",
"postcss-config-custom": "*",
"storybook-config-custom": "*",
"tsconfig": "*"
}
}
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
// eslint-disable-next-line @typescript-eslint/no-var-requires
const tailwindConfig = require('../../packages/mirinae/tailwind.config.cjs');
const tailwindConfig = require('postcss-config-custom/tailwind.config.cjs');

module.exports = {
content: [
Expand Down
File renamed without changes.
Original file line number Diff line number Diff line change
@@ -1,8 +1,11 @@
import { defineConfig } from 'vite';
import vue from '@vitejs/plugin-vue2';
import commonjs from '@rollup/plugin-commonjs';
/* eslint-disable import/no-extraneous-dependencies */
import path from 'path';

import commonjs from '@rollup/plugin-commonjs';
import vue from '@vitejs/plugin-vue2';
import { defineConfig } from 'vite';


export default defineConfig({
plugins: [vue()],
resolve: {
Expand All @@ -12,9 +15,9 @@ export default defineConfig({
},
},
optimizeDeps: {
include: ['@/styles/colors.cjs', '@/styles/web-fonts.cjs', '@/styles/screens.cjs', '@/styles/variables.cjs', '@/styles/font-size.cjs', '@/index'],
include: ['mirinae-foundation/web-fonts.cjs', 'mirinae-foundation/screens.cjs', '@/styles/colors.cjs'],
},
rollupInputOptions: {
plugins: [commonjs()]
}
});
plugins: [commonjs()],
},
});
9 changes: 0 additions & 9 deletions apps/storybook/.storybook/manager.js

This file was deleted.

5 changes: 5 additions & 0 deletions apps/unified-storybook/.eslintrc.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
module.exports = {
root: false,
extends: ['custom'],
ignorePatterns: ['**/node_modules/**'],
};
3 changes: 3 additions & 0 deletions apps/unified-storybook/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
# Transpiled code
.out
storybook-static
30 changes: 30 additions & 0 deletions apps/unified-storybook/.storybook/CloudforetTheme.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
export default {
base: 'light',
colorPrimary: '#6638B6',
colorSecondary: 'rgba(102, 56, 182, 0.9)',

// UI
appBg: 'white',
appContentBg: 'white',
appBorderColor: 'silver',
appBorderRadius: 4,

// Text colors
textColor: 'black',
textInverseColor: 'rgba(255,255,255,0.9)',

// Toolbar default and active colors
barTextColor: 'silver',
barSelectedColor: '#6638B6',
barBg: 'white',

// Form colors
inputBg: 'white',
inputBorder: 'silver',
inputTextColor: 'black',
inputBorderRadius: 4,

brandTitle: 'Cloudforet Design System',
brandUrl: 'https://github.com/cloudforet-io/console',
brandImage: './images/SpaceONE_logoTypeA.svg',
};
Loading