This is an automated email from the ASF dual-hosted git repository.

zky pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/incubator-devlake-website.git


The following commit(s) were added to refs/heads/main by this push:
     new 70e46f5d050 fix: remove dev-website-tailwind-config dependency and 
update tailwind configuration (#821)
70e46f5d050 is described below

commit 70e46f5d050e521b45b8b30a5324977c821b5bc1
Author: Klesh Wong <[email protected]>
AuthorDate: Wed Mar 4 17:59:31 2026 +0800

    fix: remove dev-website-tailwind-config dependency and update tailwind 
configuration (#821)
---
 package-lock.json  |  10 -----
 package.json       |   1 -
 tailwind.config.js |   2 +-
 tailwind.preset.js | 112 +++++++++++++++++++++++++++++++++++++++++++++++++++++
 4 files changed, 113 insertions(+), 12 deletions(-)

diff --git a/package-lock.json b/package-lock.json
index afe45bfacf6..e008ebca2e2 100644
--- a/package-lock.json
+++ b/package-lock.json
@@ -16,7 +16,6 @@
         "@tailwindcss/line-clamp": "^0.4.2",
         "autoprefixer": "^10.4.8",
         "clsx": "^1.1.1",
-        "dev-website-tailwind-config": 
"github:merico-dev/dev-website-tailwind-config",
         "mdx-mermaid": "^1.3.2",
         "mermaid": "^9.1.3",
         "postcss": "^8.4.16",
@@ -6110,11 +6109,6 @@
         "node": ">=0.8.0"
       }
     },
-    "node_modules/dev-website-tailwind-config": {
-      "version": "1.0.0",
-      "resolved": 
"git+ssh://[email protected]/merico-dev/dev-website-tailwind-config.git#62017898d43897acc108183cf8313e96e8083b25",
-      "license": "ISC"
-    },
     "node_modules/didyoumean": {
       "version": "1.2.2",
       "resolved": 
"https://registry.npmjs.org/didyoumean/-/didyoumean-1.2.2.tgz";,
@@ -18623,10 +18617,6 @@
         "minimist": "^1.2.6"
       }
     },
-    "dev-website-tailwind-config": {
-      "version": 
"git+ssh://[email protected]/merico-dev/dev-website-tailwind-config.git#62017898d43897acc108183cf8313e96e8083b25",
-      "from": 
"dev-website-tailwind-config@github:merico-dev/dev-website-tailwind-config"
-    },
     "didyoumean": {
       "version": "1.2.2",
       "resolved": 
"https://registry.npmjs.org/didyoumean/-/didyoumean-1.2.2.tgz";,
diff --git a/package.json b/package.json
index cf0954d045a..c5df89d0217 100644
--- a/package.json
+++ b/package.json
@@ -22,7 +22,6 @@
     "@tailwindcss/line-clamp": "^0.4.2",
     "autoprefixer": "^10.4.8",
     "clsx": "^1.1.1",
-    "dev-website-tailwind-config": 
"github:merico-dev/dev-website-tailwind-config",
     "mdx-mermaid": "^1.3.2",
     "mermaid": "^9.1.3",
     "postcss": "^8.4.16",
diff --git a/tailwind.config.js b/tailwind.config.js
index 00f767e59e4..62f42e07e9d 100644
--- a/tailwind.config.js
+++ b/tailwind.config.js
@@ -1,6 +1,6 @@
 /** @type {import('tailwindcss').Config} */
 
-let {tailwindConfig} = require('dev-website-tailwind-config');
+let {tailwindConfig} = require('./tailwind.preset');
 
 tailwindConfig.darkMode = ['class', '[data-theme="dark"]'];
 
diff --git a/tailwind.preset.js b/tailwind.preset.js
new file mode 100644
index 00000000000..15ba6e99284
--- /dev/null
+++ b/tailwind.preset.js
@@ -0,0 +1,112 @@
+const fontFamilySans = [
+    'ui-sans-serif',
+    'system-ui',
+    '-apple-system',
+    'BlinkMacSystemFont',
+    '"Segoe UI"',
+    'Roboto',
+    '"Helvetica Neue"',
+    'Arial',
+    '"Noto Sans"',
+    'sans-serif',
+    '"Apple Color Emoji"',
+    '"Segoe UI Emoji"',
+    '"Segoe UI Symbol"',
+    '"Noto Color Emoji"',
+  ];
+  const tailwindConfig = {
+    content: ['./src/**/*.{js,jsx,ts,tsx}'],
+    corePlugins: {
+      preflight: false,
+    },
+    theme: {
+      fontFamily: {
+        inter: ['"Inter"', ...fontFamilySans],
+      },
+      screens: {
+        // devLake sm断点
+        'sm': { 'max': '1024px' },
+        'mobile': { 'max': '550px' },
+        // devStream sm断点
+        'sm2': '640px',
+        'md': '768px',
+        'lg': '1024px',
+        'xl': '1280px',
+        '2xl': '1536px',
+      },
+      spacing: {
+        1: '8px',
+        2: '12px',
+        3: '16px',
+        4: '24px',
+        5: '32px',
+        6: '48px',
+        7: '64px',
+        8: '80px',
+        9: '96px',
+        10: '112px',
+        11: '128px',
+      },
+      extend: {
+        colors: {
+          primary: '#7497F7',
+          'primary-light': '#99B3F9',
+          'primary-100': '#F0F4FE',
+          'primary-200': '#DBE4FD',
+          'primary-300': '#BDCEFB',
+          'primary-500': '#7497F7',
+          'primary-800': '#3C5088',
+          neutral: {
+            invert: '#FFFFFF',
+            300: '#94959F',
+            400: '#70727F',
+            500: '#4D4E5F',
+            600: '#292B3F',
+          },
+          secondary: {
+            500: "#FF8B8B",
+          }
+        },
+        fontSize: {
+          // devlake
+          heading0: ['48px', { lineHeight: '64px' }],
+          heading1: ['32px', { lineHeight: '40px' }],
+          heading2: ['24px', { lineHeight: '30px' }],
+          heading3: ['20px', { lineHeight: '25px' }],
+          heading4: ['16px', { lineHeight: '20px' }],
+          label14: ['14px', { lineHeight: '20px' }],
+          label16: ['16px', { lineHeight: '24px' }],
+          label18: ['18px', { lineHeight: '24px' }],
+          label24: ['24px', { lineHeight: '32px' }],
+          // devstream
+          heading1stream: ['32px', { lineHeight: 1.25 }],
+          heading2stream: ['24px', { lineHeight: 1.25 }],
+          heading3stream: ['20px', { lineHeight: 1.25 }],
+          heading4stream: ['16px', { lineHeight: 1.25 }],
+          label14stream: ['14px', { lineHeight: 1.43 }],
+          label18stream: ['18px', { lineHeight: 1.56 }],
+          // common
+          body: ['14px', { lineHeight: 1.214 }],
+          "body-sm": ['12px', { lineHeight: 1.25 }],
+          "body-large": ['24px', { lineHeight: '32px' }],
+        },
+        dropShadow: {
+          xl: ['0px 3.2px 16px rgba(153, 179, 249, 0.1)'],
+        },
+        // 属性值非响应式,无需修改
+        boxShadow: {
+          sm: '0px 2.4px 4.8px -0.8px rgba(0, 0, 0, 0.2), 0px 1.6px 8px 
rgba(0, 0, 0, 0.2)',
+          lg: '0px 4.8px 9.6px -0.8px rgba(0, 0, 0, 0.2), 0px 3.2px 16px 
rgba(0, 0, 0, 0.2)',
+          lower: '0px 1.2px 2.4px -0.8px rgba(0, 0, 0, 0.1), 0px 0.8px 4px 
rgba(0, 0, 0, 0.07)',
+          high: '0px 9.6px 19.2px -0.8px rgba(0, 0, 0, 0.1), 0px 6.4px 32px 
rgba(0, 0, 0, 0.07)',
+          card: '0px 20px 64px -0.8px rgba(0, 0, 0, 0.06)',
+          hide: '0px 0px 0px 0px rgba(0, 0, 0, 0)',
+        },
+      },
+    },
+    plugins: [],
+  };
+  
+  module.exports = {
+    tailwindConfig
+  }
\ No newline at end of file

Reply via email to