diff --git a/.github/pull_request_template.yml b/.github/pull_request_template.yml new file mode 100644 index 0000000..8779fb3 --- /dev/null +++ b/.github/pull_request_template.yml @@ -0,0 +1,43 @@ +name: '๐Ÿ“ PR Template (Solo)' +description: 'ํ˜ผ์ž ์“ฐ๋Š” ์ปดํฌ๋„ŒํŠธ PR ํ…œํ”Œ๋ฆฟ' +labels: ['pr'] +body: + - type: input + id: title + attributes: + label: 'PR ์ œ๋ชฉ' + description: '์ด๋ฒˆ PR์„ ํ•œ ์ค„๋กœ ์š”์•ฝ' + placeholder: '์˜ˆ: Button ์ปดํฌ๋„ŒํŠธ disabled ๋ฒ„๊ทธ ์ˆ˜์ •' + validations: + required: true + + - type: textarea + id: description + attributes: + label: '๋ณ€๊ฒฝ ๋‚ด์šฉ' + description: '๋ฌด์—‡์„ ๋ฐ”๊ฟจ๋Š”์ง€ ๊ฐ„๋‹จํ•˜๊ฒŒ ์ž‘์„ฑ' + placeholder: "- Button disabled ์ƒํƒœ ํด๋ฆญ ๋ฐฉ์ง€\n- ๊ด€๋ จ ํ…Œ์ŠคํŠธ ์ถ”๊ฐ€" + validations: + required: true + + - type: textarea + id: purpose + attributes: + label: '๋ชฉ์  / ์ด์œ ' + description: '์™œ ๋ฐ”๊ฟจ๋Š”์ง€ ํ•œ๋‘ ์ค„๋กœ' + placeholder: '์˜ˆ: ์‚ฌ์šฉ์ž ๊ฒฝํ—˜ ๊ฐœ์„ , ๋ฒ„๊ทธ ์ˆ˜์ •' + validations: + required: true + + - type: checkboxes + id: checklist + attributes: + label: 'ํ™•์ธ ์‚ฌํ•ญ' + description: 'PR ์ „์— ์ฒดํฌํ•  ํ•ญ๋ชฉ' + options: + - label: '๋นŒ๋“œ ํ†ต๊ณผ โœ…' + value: 'build_passed' + - label: 'ํ…Œ์ŠคํŠธ ํ†ต๊ณผ โœ…' + value: 'tests_passed' + - label: '๋ถˆํ•„์š”ํ•œ console.log ์ œ๊ฑฐ โœ…' + value: 'console_cleaned' diff --git a/.github/workflows/lint-and-typecheck.yml b/.github/workflows/lint-and-typecheck.yml index 5fa8d1e..993f3a7 100644 --- a/.github/workflows/lint-and-typecheck.yml +++ b/.github/workflows/lint-and-typecheck.yml @@ -18,10 +18,14 @@ jobs: uses: actions/setup-node@v4 with: node-version: 20 - cache: "pnpm" + + - name: Setup pnpm + uses: pnpm/action-setup@v2 + with: + version: 8 - name: Install dependencies - run: pnpm ci + run: pnpm install - name: Run ESLint run: pnpm run lint diff --git a/.prettierrc b/.prettierrc new file mode 100644 index 0000000..680dbb5 --- /dev/null +++ b/.prettierrc @@ -0,0 +1,7 @@ +{ + "singleQuote": true, + "trailingComma": "none", + "semi": true, + "arrowParens": "always", + "endOfLine": "lf" +} diff --git a/esbuild.config.js b/esbuild.config.js new file mode 100644 index 0000000..66552b3 --- /dev/null +++ b/esbuild.config.js @@ -0,0 +1,7 @@ +const sassPlugin = require('esbuild-plugin-sass'); +require('esbuild').build({ + entryPoints: ['src/index.tsx'], + bundle: true, + outdir: 'dist', + plugins: [sassPlugin()] +}); diff --git a/package.json b/package.json index c0aad11..419af69 100644 --- a/package.json +++ b/package.json @@ -40,6 +40,7 @@ "@vitejs/plugin-react": "^5.0.0", "@vitest/browser": "^3.2.4", "@vitest/coverage-v8": "^3.2.4", + "esbuild-plugin-sass": "^1.0.1", "eslint": "^9.33.0", "eslint-config-prettier": "^10.1.8", "eslint-plugin-react": "^7.37.5", diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index 77bb1a0..ace07dd 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -63,6 +63,9 @@ importers: '@vitest/coverage-v8': specifier: ^3.2.4 version: 3.2.4(@vitest/browser@3.2.4)(vitest@3.2.4) + esbuild-plugin-sass: + specifier: ^1.0.1 + version: 1.0.1(esbuild@0.25.9) eslint: specifier: ^9.33.0 version: 9.33.0 @@ -1026,6 +1029,10 @@ packages: any-promise@1.3.0: resolution: {integrity: sha512-7UvmKalWRt1wgjL1RrGxoSJW/0QZFIegpeGvZG9kjp8vrRu55XTHbwnqq2GpXm9uLbcuhxm3IqX9OB4MZR1b2A==} + anymatch@3.1.3: + resolution: {integrity: sha512-KMReFUr0B4t+D+OBkjR3KYqvocp2XaSzO55UcB6mgQMd3KbcE+mWTyvVV7D/zsdEbNnV6acZUutkiHQXvTr1Rw==} + engines: {node: '>= 8'} + argparse@2.0.1: resolution: {integrity: sha512-8+9WqebbFzpX9OR+Wa6O29asIogeRMzcGtAINdpMHHyAg10f05aSFVBbcEqGf/PXw1EjAZ+q2/bEBg3DvurK3Q==} @@ -1094,6 +1101,10 @@ packages: resolution: {integrity: sha512-aVNobHnJqLiUelTaHat9DZ1qM2w0C0Eym4LPI/3JxOnSokGVdsl1T1kN7TFvsEAD8G47A6VKQ0TVHqbBnYMJlQ==} engines: {node: '>=12.0.0'} + binary-extensions@2.3.0: + resolution: {integrity: sha512-Ceh+7ox5qe7LJuLHoY0feh3pHuUDHAcRUeyL2VYghZwfpkNIy/+8Ocg0a3UuSoYzavmylwuLWQOf3hl0jjMMIw==} + engines: {node: '>=8'} + brace-expansion@1.1.12: resolution: {integrity: sha512-9T9UjW3r0UW5c1Q7GTwllptXwhvYmEzFhzMfZ9H7FQWt+uZePjZPjBP/W1ZEyZ1twGWom5/56TF4lPcqjnDHcg==} @@ -1150,6 +1161,10 @@ packages: resolution: {integrity: sha512-OAlb+T7V4Op9OwdkjmguYRqncdlx5JiofwOAUkmTF+jNdHwzTaTs4sRAGpzLF3oOz5xAyDGrPgeIDFQmDOTiJw==} engines: {node: '>= 16'} + chokidar@3.6.0: + resolution: {integrity: sha512-7VT13fmjotKpGipCW9JEQAusEPE+Ei8nl6/g4FBAmIm0GOOLMua9NDDo/DWp0ZAxCr3cPq5ZpBqmPAQgDda2Pw==} + engines: {node: '>= 8.10.0'} + chokidar@4.0.3: resolution: {integrity: sha512-Qgzu8kfBvo+cA4962jnP1KkS6Dop5NS6g7R5LFYJr4b8Ub94PPQXUksCw9PvXoeXPRRddRNC5C1JQUR2SMGtnA==} engines: {node: '>= 14.16.0'} @@ -1194,6 +1209,10 @@ packages: resolution: {integrity: sha512-uV2QOWP2nWzsy2aMp8aRibhi9dlzF5Hgh5SHaB9OiTGEyDTiJJyx0uy51QXdyWbtAHNua4XJzUKca3OzKUd3vA==} engines: {node: '>= 8'} + css-tree@1.1.3: + resolution: {integrity: sha512-tRpdppF7TRazZrjJ6v3stzv93qxRcSsFmW6cX0Zm2NVKpxE1WV1HblnghVv9TreireHkqI/VDEsfolRF1p6y7Q==} + engines: {node: '>=8.0.0'} + css.escape@1.5.1: resolution: {integrity: sha512-YUifsXXuknHlUsmlgyY0PKzgPOr7/FjCePfHNt0jxm83wHZi44VDMQ7/fGNkjY3/jV1MC+1CmZbaHzugyeRtpg==} @@ -1329,6 +1348,11 @@ packages: resolution: {integrity: sha512-w+5mJ3GuFL+NjVtJlvydShqE1eN3h3PbI7/5LAsYJP/2qtuMXjfL2LpHSRqo4b4eSF5K/DH1JXKUAHSB2UW50g==} engines: {node: '>= 0.4'} + esbuild-plugin-sass@1.0.1: + resolution: {integrity: sha512-YFxjzD9Z1vz92QCJcAmCO15WVCUiOobw9ypdVeMsW+xa6S+zqryLUIh8d3fe/UkRHRO5PODZz/3xDAQuEXZwmQ==} + peerDependencies: + esbuild: '>=0.11.14' + esbuild-register@3.6.0: resolution: {integrity: sha512-H2/S7Pm8a9CL1uhp9OvjwrBh5Pvx0H8qVOxNu8Wed9Y7qv56MPtq+GGM8RJpq6glYJn9Wspr8uw7l55uyinNeg==} peerDependencies: @@ -1497,6 +1521,13 @@ packages: resolution: {integrity: sha512-gIXjKqtFuWEgzFRJA9WCQeSJLZDjgJUOMCMzxtvFq/37KojM1BFGufqsCy0r4qSQmYLsZYMeyRqzIWOMup03sw==} engines: {node: '>=14'} + fs-extra@10.0.0: + resolution: {integrity: sha512-C5owb14u9eJwizKGdchcDUQeFtlSHHthBk8pbX9Vc1PFZrLombudjDnNns88aYslCyF6IY5SUw3Roz6xShcEIQ==} + engines: {node: '>=12'} + + fs.realpath@1.0.0: + resolution: {integrity: sha512-OO0pH2lK6a0hZnAdau5ItzHPI6pUlvI7jMVnxUQRtw4owF2wk8lOSabtGDCTP4Ggrg2MbGnWO9X8K1t4+fGMDw==} + fsevents@2.3.2: resolution: {integrity: sha512-xiqMQR4xAeHTuB9uWm+fFRcIOgKBMiOBP+eXiyT7jsgVCq1bkVygt00oASowB7EdtpOHaaPgKt812P9ab+DDKA==} engines: {node: ^8.16.0 || ^10.6.0 || >=11.0.0} @@ -1545,6 +1576,10 @@ packages: resolution: {integrity: sha512-7Bv8RF0k6xjo7d4A/PxYLbUCfb6c+Vpd2/mB2yRDlew7Jb5hEXiCD9ibfO7wpk8i4sevK6DFny9h7EYbM3/sHg==} hasBin: true + glob@7.2.3: + resolution: {integrity: sha512-nFR0zLpU2YCaRxwoCJvL6UvCH2JFyFVIvwTLsIf21AuHlMskA1hhTdk+LlYJtOlYt9v6dvszD2BGRqBL+iQK9Q==} + deprecated: Glob versions prior to v9 are no longer supported + globals@14.0.0: resolution: {integrity: sha512-oahGvuMGQlPw/ivIYBjVSrWAfWLBeku5tpPE2fOPLi+WHffIWbuh2tCjhyQhTBPMf5E9jDEH4FOmTYgYwbKwtQ==} engines: {node: '>=18'} @@ -1621,6 +1656,9 @@ packages: resolution: {integrity: sha512-Hs59xBNfUIunMFgWAbGX5cq6893IbWg4KnrjbYwX3tx0ztorVgTDA6B2sxf8ejHJ4wz8BqGUMYlnzNBer5NvGg==} engines: {node: '>= 4'} + immutable@4.3.7: + resolution: {integrity: sha512-1hqclzwYwjRDFLjcFxOM5AYkkG0rpFPpr1RLPMEuGczoS7YA8gLhy8SWXYRAA/XwfEHpfo3cw5JGioS32fnMRw==} + immutable@5.1.3: resolution: {integrity: sha512-+chQdDfvscSF1SJqv2gn4SRO2ZyS3xL3r7IW/wWEEzrzLisnOlKiQu5ytC/BVNcS15C39WT2Hg/bjKjDMcu+zg==} @@ -1636,6 +1674,13 @@ packages: resolution: {integrity: sha512-EdDDZu4A2OyIK7Lr/2zG+w5jmbuk1DVBnEwREQvBzspBJkCEbRa8GxU1lghYcaGJCnRWibjDXlq779X1/y5xwg==} engines: {node: '>=8'} + inflight@1.0.6: + resolution: {integrity: sha512-k92I/b08q4wvFscXCLvqfsHCrjrF7yiXsQuIVvVE7N82W3+aqpzuUdBbfhWcy/FZR3/4IgflMgKLOsvPDrGCJA==} + deprecated: This module is not supported, and leaks memory. Do not use it. Check out lru-cache if you want a good and tested way to coalesce async requests by a key value, which is much more comprehensive and powerful. + + inherits@2.0.4: + resolution: {integrity: sha512-k/vGaX4/Yla3WzyMCvTQOXYeIHvqOKtnqBduzTHpzpQZzAskKMhZ2K+EnBiSM9zGSoIFeMpXKxa4dYeZIQqewQ==} + internal-slot@1.1.0: resolution: {integrity: sha512-4gd7VpWNQNB4UKKCFFVcp1AVv+FMOgs9NKzjHKusc8jTMhd5eL1NqQqOpE0KzMds804/yHlglp3uxgluOqAPLw==} engines: {node: '>= 0.4'} @@ -1652,6 +1697,10 @@ packages: resolution: {integrity: sha512-n4ZT37wG78iz03xPRKJrHTdZbe3IicyucEtdRsV5yglwc3GyUfbAfpSeD0FJ41NbUNSt5wbhqfp1fS+BgnvDFQ==} engines: {node: '>= 0.4'} + is-binary-path@2.1.0: + resolution: {integrity: sha512-ZMERYes6pDydyuGidse7OsHxtbI7WVeUEozgR/g7rd0xUimYNlvZRE/K2MgZTjWy725IfelLeVcEM97mmtRGXw==} + engines: {node: '>=8'} + is-boolean-object@1.2.2: resolution: {integrity: sha512-wa56o2/ElJMYqjCjGkXri7it5FbebW5usLw/nPmCMs5DeZ7eziSYZhSmPRn0txqeW4LnAmQQU7FgqLpsEFKM4A==} engines: {node: '>= 0.4'} @@ -1901,6 +1950,9 @@ packages: resolution: {integrity: sha512-/IXtbwEk5HTPyEwyKX6hGkYXxM9nbj64B+ilVJnC/R6B0pH5G4V3b0pVbL7DBj4tkhBAppbQUlf6F6Xl9LHu1g==} engines: {node: '>= 0.4'} + mdn-data@2.0.14: + resolution: {integrity: sha512-dn6wd0uw5GsdswPFfsgMp5NSB0/aDe6fK94YJV/AJDYXL6HVLWBsxeq7js7Ad+mU2K9LAlwpk6kN2D5mwCPVow==} + merge2@1.4.1: resolution: {integrity: sha512-8q7VEgMJW4J8tcfVPy8g09NcQwZdbwFEqhe/WZkoIzjn/3TGDwtOCYtXGxA3O8tPzpczCCDgv+P2P5y00ZJOOg==} engines: {node: '>= 8'} @@ -1954,6 +2006,10 @@ packages: node-releases@2.0.19: resolution: {integrity: sha512-xxOWJsBKtzAq7DY0J+DTzuz58K8e7sJbdgwkbMWQe8UYB6ekmsQ45q0M/tJDsGaZmbC+l7n57UV8Hl5tHxO9uw==} + normalize-path@3.0.0: + resolution: {integrity: sha512-6eZs5Ls3WtCisHWp9S2GUy8dqkpGi4BVSz3GaqiE6ezub0512ESztXUwUB6C6IKbQkY2Pnb/mD4WYojCRwcwLA==} + engines: {node: '>=0.10.0'} + nwsapi@2.2.22: resolution: {integrity: sha512-ujSMe1OWVn55euT1ihwCI1ZcAaAU3nxUiDwfDQldc51ZXaB9m2AyOn6/jh1BLe2t/G8xd6uKG1UBF2aZJeg2SQ==} @@ -1985,6 +2041,9 @@ packages: resolution: {integrity: sha512-gXah6aZrcUxjWg2zR2MwouP2eHlCBzdV4pygudehaKXSGW4v2AsRQUK+lwwXhii6KFZcunEnmSUoYp5CXibxtA==} engines: {node: '>= 0.4'} + once@1.4.0: + resolution: {integrity: sha512-lNaJgI+2Q5URQBkccEKHTQOPaXdUxnZZElQTZY0MFUAuaEqe1E+Nyvgdz/aIyNi6Z9MzO5dv1H8n58/GELp3+w==} + open@8.4.2: resolution: {integrity: sha512-7x81NCL719oNbsq/3mh+hVrAWmFuEYUqrq/Iw3kUzH8ReypT9QQ0BLoJS7/G9k6N81XjW4qHWtjWwe/9eLy1EQ==} engines: {node: '>=12'} @@ -2031,6 +2090,10 @@ packages: resolution: {integrity: sha512-RjhtfwJOxzcFmNOi6ltcbcu4Iu+FL3zEj83dk4kAS+fVpTxXLO1b38RvJgT/0QwvV/L3aY9TAnyv0EOqW4GoMQ==} engines: {node: ^12.20.0 || ^14.13.1 || >=16.0.0} + path-is-absolute@1.0.1: + resolution: {integrity: sha512-AVbw3UJ2e9bq64vSaS9Am0fje1Pa8pbGqTTsmXfaIiMpnr5DlDhfJOuLj9Sf95ZPVDAUerDfEk88MPmPe7UCQg==} + engines: {node: '>=0.10.0'} + path-key@3.1.1: resolution: {integrity: sha512-ojmeN0qd+y0jszEtoY48r0Peq5dwMEkIlCOu6Q5f41lfkswXuKtYrhgoTpLnyIcHm24Uhqx+5Tqm2InSwLhE6Q==} engines: {node: '>=8'} @@ -2158,6 +2221,10 @@ packages: resolution: {integrity: sha512-w8nqGImo45dmMIfljjMwOGtbmC/mk4CMYhWIicdSflH91J9TyCyczcPFXJzrZ/ZXcgGRFeP6BU0BEJTw6tZdfQ==} engines: {node: '>=0.10.0'} + readdirp@3.6.0: + resolution: {integrity: sha512-hOS089on8RduqdbhvQ5Z37A0ESjsqz6qnRcffsMU3495FuTdqSm+7bhJ29JvIOsBDEEnan5DPu9t3To9VRlMzA==} + engines: {node: '>=8.10.0'} + readdirp@4.1.2: resolution: {integrity: sha512-GDhwkLfywWL2s6vEjyhri+eXmfH6j1L7JE27WhqLeYzoh/A3DBaYGEj2H/HFZCn/kMfim73FXxEJTw06WtxQwg==} engines: {node: '>= 14.18.0'} @@ -2199,6 +2266,11 @@ packages: resolution: {integrity: sha512-g6QUff04oZpHs0eG5p83rFLhHeV00ug/Yf9nZM6fLeUrPguBTkTQOdpAWWspMh55TZfVQDPaN3NQJfbVRAxdIw==} engines: {iojs: '>=1.0.0', node: '>=0.10.0'} + rimraf@3.0.2: + resolution: {integrity: sha512-JZkJMZkAGFFPP2YqXZXPbMlMBgsxzE8ILs4lMIX/2o0L9UBw9O/Y3o6wFw/i9YLapcUJWwqbi3kdxIPdC62TIA==} + deprecated: Rimraf versions prior to v4 are no longer supported + hasBin: true + rollup@4.46.2: resolution: {integrity: sha512-WMmLFI+Boh6xbop+OAGo9cQ3OgX9MIg7xOQjn+pTCwOkk+FNDAeAemXkJ3HzDJrVXleLOFVa1ipuc1AmEx1Dwg==} engines: {node: '>=18.0.0', npm: '>=8.0.0'} @@ -2225,6 +2297,11 @@ packages: safer-buffer@2.1.2: resolution: {integrity: sha512-YZo3K82SD7Riyi0E1EQPojLz7kpepnSQI9IyPbHHg1XXXevb5dJI7tpyN2ADxGcQbHG7vcyRHk0cbwqcQriUtg==} + sass@1.47.0: + resolution: {integrity: sha512-GtXwvwgD7/6MLUZPnlA5/8cdRgC9SzT5kAnnJMRmEZQFRE3J56Foswig4NyyyQGsnmNvg6EUM/FP0Pe9Y2zywQ==} + engines: {node: '>=8.9.0'} + hasBin: true + sass@1.90.0: resolution: {integrity: sha512-9GUyuksjw70uNpb1MTYWsH9MQHOHY6kwfnkafC24+7aOMZn9+rVMBxRbLvw756mrBFbIsFg6Xw9IkR2Fnn3k+Q==} engines: {node: '>=14.0.0'} @@ -2441,6 +2518,10 @@ packages: resolution: {integrity: sha512-WMi/OQ2axVTf/ykqCQgXiIct+mSQDFdH2fkwhPwgEwvJ1kSzZRiinb0zF2Xb8u4+OqPChmyI6MEu4EezNJz+FQ==} hasBin: true + tmp@0.2.1: + resolution: {integrity: sha512-76SUhtfqR2Ijn+xllcI5P1oyannHNHByD80W1q447gU3mp9G9PSpGdWmjUOHRDPiHYacIk66W7ubDTuPF3BEtQ==} + engines: {node: '>=8.17.0'} + to-regex-range@5.0.1: resolution: {integrity: sha512-65P7iz6X5yEr1cwcgvQxbbIw7Uk3gOy5dIdtZ4rDveLqhrdJP+Li/Hx6tyK0NEb+2GCyneCMJiGqrADCSNk8sQ==} engines: {node: '>=8.0'} @@ -2706,6 +2787,9 @@ packages: resolution: {integrity: sha512-si7QWI6zUMq56bESFvagtmzMdGOtoxfR+Sez11Mobfc7tm+VkUckk9bW2UeffTGVUbOksxmSw0AA2gs8g71NCQ==} engines: {node: '>=12'} + wrappy@1.0.2: + resolution: {integrity: sha512-l4Sp/DRseor9wL6EvV2+TuQn63dMkPjZ/sp9XkghTEbV9KlPS1xUsZ3u7/IQO4wxtcFB4bgpQPRcR3QCvezPcQ==} + ws@8.18.3: resolution: {integrity: sha512-PEIGCY5tSlUt50cqyMXfCzX+oOPqN0vuGqWzbcJ2xvnkzkq46oOpz7dQaTDBdfICb4N14+GARUDw2XV2N4tvzg==} engines: {node: '>=10.0.0'} @@ -3617,6 +3701,11 @@ snapshots: any-promise@1.3.0: {} + anymatch@3.1.3: + dependencies: + normalize-path: 3.0.0 + picomatch: 2.3.1 + argparse@2.0.1: {} aria-query@5.3.0: @@ -3708,6 +3797,8 @@ snapshots: dependencies: open: 8.4.2 + binary-extensions@2.3.0: {} + brace-expansion@1.1.12: dependencies: balanced-match: 1.0.2 @@ -3771,6 +3862,18 @@ snapshots: check-error@2.1.1: {} + chokidar@3.6.0: + dependencies: + anymatch: 3.1.3 + braces: 3.0.3 + glob-parent: 5.1.2 + is-binary-path: 2.1.0 + is-glob: 4.0.3 + normalize-path: 3.0.0 + readdirp: 3.6.0 + optionalDependencies: + fsevents: 2.3.3 + chokidar@4.0.3: dependencies: readdirp: 4.1.2 @@ -3799,6 +3902,11 @@ snapshots: shebang-command: 2.0.0 which: 2.0.2 + css-tree@1.1.3: + dependencies: + mdn-data: 2.0.14 + source-map: 0.6.1 + css.escape@1.5.1: {} cssstyle@4.6.0: @@ -3991,6 +4099,14 @@ snapshots: is-date-object: 1.1.0 is-symbol: 1.1.1 + esbuild-plugin-sass@1.0.1(esbuild@0.25.9): + dependencies: + css-tree: 1.1.3 + esbuild: 0.25.9 + fs-extra: 10.0.0 + sass: 1.47.0 + tmp: 0.2.1 + esbuild-register@3.6.0(esbuild@0.25.9): dependencies: debug: 4.4.1 @@ -4216,6 +4332,14 @@ snapshots: cross-spawn: 7.0.6 signal-exit: 4.1.0 + fs-extra@10.0.0: + dependencies: + graceful-fs: 4.2.11 + jsonfile: 6.2.0 + universalify: 2.0.1 + + fs.realpath@1.0.0: {} + fsevents@2.3.2: optional: true @@ -4278,6 +4402,15 @@ snapshots: package-json-from-dist: 1.0.1 path-scurry: 1.11.1 + glob@7.2.3: + dependencies: + fs.realpath: 1.0.0 + inflight: 1.0.6 + inherits: 2.0.4 + minimatch: 3.1.2 + once: 1.4.0 + path-is-absolute: 1.0.1 + globals@14.0.0: {} globals@16.3.0: {} @@ -4289,8 +4422,7 @@ snapshots: gopd@1.2.0: {} - graceful-fs@4.2.11: - optional: true + graceful-fs@4.2.11: {} graphemer@1.4.0: {} @@ -4344,6 +4476,8 @@ snapshots: ignore@7.0.5: {} + immutable@4.3.7: {} + immutable@5.1.3: {} import-fresh@3.3.1: @@ -4355,6 +4489,13 @@ snapshots: indent-string@4.0.0: {} + inflight@1.0.6: + dependencies: + once: 1.4.0 + wrappy: 1.0.2 + + inherits@2.0.4: {} + internal-slot@1.1.0: dependencies: es-errors: 1.3.0 @@ -4379,6 +4520,10 @@ snapshots: dependencies: has-bigints: 1.1.0 + is-binary-path@2.1.0: + dependencies: + binary-extensions: 2.3.0 + is-boolean-object@1.2.2: dependencies: call-bound: 1.0.4 @@ -4637,6 +4782,8 @@ snapshots: math-intrinsics@1.1.0: {} + mdn-data@2.0.14: {} + merge2@1.4.1: {} micromatch@4.0.8: @@ -4684,6 +4831,8 @@ snapshots: node-releases@2.0.19: {} + normalize-path@3.0.0: {} + nwsapi@2.2.22: {} object-assign@4.1.1: {} @@ -4722,6 +4871,10 @@ snapshots: define-properties: 1.2.1 es-object-atoms: 1.1.1 + once@1.4.0: + dependencies: + wrappy: 1.0.2 + open@8.4.2: dependencies: define-lazy-prop: 2.0.0 @@ -4773,6 +4926,8 @@ snapshots: path-exists@5.0.0: {} + path-is-absolute@1.0.1: {} + path-key@3.1.1: {} path-parse@1.0.7: {} @@ -4879,6 +5034,10 @@ snapshots: react@19.1.1: {} + readdirp@3.6.0: + dependencies: + picomatch: 2.3.1 + readdirp@4.1.2: {} recast@0.23.11: @@ -4932,6 +5091,10 @@ snapshots: reusify@1.1.0: {} + rimraf@3.0.2: + dependencies: + glob: 7.2.3 + rollup@4.46.2: dependencies: '@types/estree': 1.0.8 @@ -4985,6 +5148,12 @@ snapshots: safer-buffer@2.1.2: {} + sass@1.47.0: + dependencies: + chokidar: 3.6.0 + immutable: 4.3.7 + source-map-js: 1.2.1 + sass@1.90.0: dependencies: chokidar: 4.0.3 @@ -5247,6 +5416,10 @@ snapshots: dependencies: tldts-core: 6.1.86 + tmp@0.2.1: + dependencies: + rimraf: 3.0.2 + to-regex-range@5.0.1: dependencies: is-number: 7.0.0 @@ -5560,6 +5733,8 @@ snapshots: string-width: 5.1.2 strip-ansi: 7.1.0 + wrappy@1.0.2: {} + ws@8.18.3: {} xml-name-validator@5.0.0: {} diff --git a/src/App.tsx b/src/App.tsx index e9cbc83..aca2d08 100644 --- a/src/App.tsx +++ b/src/App.tsx @@ -1,21 +1,13 @@ -import { useState } from 'react' -import reactLogo from './assets/react.svg' +import { useState } from 'react'; + // import viteLogo from '/vite.svg' -import './App.css' +import './App.css'; function App() { - const [count, setCount] = useState(0) + const [count, setCount] = useState(0); return ( <> -
- {/* - Vite logo - */} - - React logo - -

Vite + React

); diff --git a/src/public/vite.svg b/src/public/vite.svg deleted file mode 100644 index e7b8dfb..0000000 --- a/src/public/vite.svg +++ /dev/null @@ -1 +0,0 @@ - \ No newline at end of file diff --git a/src/stories/main.ts b/src/stories/main.ts index c9ffe4a..172d56c 100644 --- a/src/stories/main.ts +++ b/src/stories/main.ts @@ -1,8 +1,8 @@ -import type { StorybookConfig } from "@storybook/react-vite"; +import type { StorybookConfig } from '@storybook/react-vite'; const config: StorybookConfig = { - stories: ["../src/**/*.stories.@(ts|tsx|mdx)"], - addons: ["@storybook/addon-essentials", "@storybook/addon-a11y"], - framework: { name: "@storybook/react-vite", options: {} }, + stories: ['../src/**/*.stories.@(ts|tsx|mdx)'], + addons: ['@storybook/addon-essentials', '@storybook/addon-a11y'], + framework: { name: '@storybook/react-vite', options: {} } }; export default config; diff --git a/src/styles/_mixins.scss b/src/styles/_mixins.scss index d0ef997..175dd12 100644 --- a/src/styles/_mixins.scss +++ b/src/styles/_mixins.scss @@ -1,4 +1,4 @@ -@use "variables" as v; +@use 'variables' as v; // ๋ฐ˜์‘ํ˜• ๋ฏธ๋””์–ด ์ฟผ๋ฆฌ ๋ฏน์Šค์ธ @mixin mq($breakpoint) { @@ -10,9 +10,10 @@ } // ํƒ€์ดํฌ๊ทธ๋ž˜ํ”ผ ๋ฏน์Šค์ธ -@mixin text-style($size) { +@mixin text-style($size, $weight: 400) { font-size: map-get(map-get(v.$typography, $size), fontSize); line-height: map-get(map-get(v.$typography, $size), lineHeight); + font-weight: $weight; } // flex ๋ฏน์Šค์ธ diff --git a/src/styles/_variables.scss b/src/styles/_variables.scss index d215356..86ae1ca 100644 --- a/src/styles/_variables.scss +++ b/src/styles/_variables.scss @@ -1,62 +1,50 @@ // ์ƒ‰์ƒ ๋ณ€์ˆ˜ $colors: ( - // ๋ธ”๋ž™/๊ทธ๋ ˆ์ด/ํ™”์ดํŠธ ๊ณ„์—ด - black: #000000, - gray-800: #171717, - gray-700: #333236, - gray-600: #4b4b4b, - gray-500: #787486, - gray-400: #9fa6b2, - gray-300: #d9d9d9, + black: #000, + white: #fff, gray-200: #eeeeee, - gray-100: #fafafa, - white: #ffffff, - - // ์ปฌ๋Ÿฌ ๊ณ„์—ด - violet_5534DA: #5534da, - violet_8: #f1effd, - red_D6173A: #d6173a, - green_7AC555: #7ac555, - purple_760DDE: #760dde, - orange_FFA500: #ffa500, - blue_76A5EA: #76a5ea, - pink_E876EA: #e876ea + gray-300: #e0e0e0, + gray-400: #bdbdbd, + gray-500: #9e9e9e, + gray-900: #212121, + red_btn: #d43c3c, + red_btn_hover: #b92a2a ); // ํƒ€์ดํฌ๊ทธ๋ž˜ํ”ผ ๋ณ€์ˆ˜ $typography: ( xs: ( fontSize: 12px, - lineHeight: 1.5, + lineHeight: 1.5 ), sm: ( fontSize: 13px, - lineHeight: 1.69, + lineHeight: 1.69 ), md: ( fontSize: 14px, - lineHeight: 1.71, + lineHeight: 1.71 ), lg: ( fontSize: 16px, - lineHeight: 1.625, + lineHeight: 1.625 ), - "2lg": ( + '2lg': ( fontSize: 18px, - lineHeight: 1.556, + lineHeight: 1.556 ), xl: ( fontSize: 20px, - lineHeight: 1.6, + lineHeight: 1.6 ), - "2xl": ( + '2xl': ( fontSize: 24px, - lineHeight: 1.333, + lineHeight: 1.333 ), - "3xl": ( + '3xl': ( fontSize: 32px, - lineHeight: 1.313, - ), + lineHeight: 1.313 + ) ); // ๋ธŒ๋ ˆ์ดํฌํฌ์ธํŠธ ๋ณ€์ˆ˜ diff --git a/tsconfig.json b/tsconfig.json index c11a079..634f3bb 100644 --- a/tsconfig.json +++ b/tsconfig.json @@ -5,6 +5,8 @@ { "path": "./tsconfig.node.json" } ], "compilerOptions": { + "jsx": "react-jsx", + "moduleResolution": "node", "baseUrl": "src", "paths": { "@/*": ["./*"] diff --git a/tsup.config.ts b/tsup.config.ts new file mode 100644 index 0000000..d21207b --- /dev/null +++ b/tsup.config.ts @@ -0,0 +1,11 @@ +import { defineConfig } from 'tsup'; +import sassPlugin from 'esbuild-plugin-sass'; + +export default defineConfig({ + entry: ['src/index.ts'], + dts: true, + format: ['esm', 'cjs'], + outDir: 'dist', + clean: true, + esbuildPlugins: [sassPlugin()] +});