generated from sonofmagic/npm-lib-template
-
-
Notifications
You must be signed in to change notification settings - Fork 92
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
5187b9a
commit 84f7c0e
Showing
7 changed files
with
133 additions
and
24 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,7 @@ | ||
{ | ||
"recommendations": [ | ||
"dbaeumer.vscode-eslint", | ||
"stylelint.vscode-stylelint" | ||
"stylelint.vscode-stylelint", | ||
"bradlc.vscode-tailwindcss" | ||
] | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,56 @@ | ||
// https://github.com/tailwindlabs/tailwindcss/discussions/5258 | ||
{ | ||
"version": 1.1, | ||
"atDirectives": [ | ||
{ | ||
"name": "@tailwind", | ||
"description": "Use the `@tailwind` directive to insert Tailwind's `base`, `components`, `utilities` and `screens` styles into your CSS.", | ||
"references": [ | ||
{ | ||
"name": "Tailwind Documentation", | ||
"url": "https://tailwindcss.com/docs/functions-and-directives#tailwind" | ||
} | ||
] | ||
}, | ||
{ | ||
"name": "@apply", | ||
"description": "Use the `@apply` directive to inline any existing utility classes into your own custom CSS. This is useful when you find a common utility pattern in your HTML that you’d like to extract to a new component.", | ||
"references": [ | ||
{ | ||
"name": "Tailwind Documentation", | ||
"url": "https://tailwindcss.com/docs/functions-and-directives#apply" | ||
} | ||
] | ||
}, | ||
{ | ||
"name": "@responsive", | ||
"description": "You can generate responsive variants of your own classes by wrapping their definitions in the `@responsive` directive:\n```css\n@responsive {\n .alert {\n background-color: #E53E3E;\n }\n}\n```\n", | ||
"references": [ | ||
{ | ||
"name": "Tailwind Documentation", | ||
"url": "https://tailwindcss.com/docs/functions-and-directives#responsive" | ||
} | ||
] | ||
}, | ||
{ | ||
"name": "@screen", | ||
"description": "The `@screen` directive allows you to create media queries that reference your breakpoints by **name** instead of duplicating their values in your own CSS:\n```css\n@screen sm {\n /* ... */\n}\n```\n…gets transformed into this:\n```css\n@media (min-width: 640px) {\n /* ... */\n}\n```\n", | ||
"references": [ | ||
{ | ||
"name": "Tailwind Documentation", | ||
"url": "https://tailwindcss.com/docs/functions-and-directives#screen" | ||
} | ||
] | ||
}, | ||
{ | ||
"name": "@variants", | ||
"description": "Generate `hover`, `focus`, `active` and other **variants** of your own utilities by wrapping their definitions in the `@variants` directive:\n```css\n@variants hover, focus {\n .btn-brand {\n background-color: #3182CE;\n }\n}\n```\n", | ||
"references": [ | ||
{ | ||
"name": "Tailwind Documentation", | ||
"url": "https://tailwindcss.com/docs/functions-and-directives#variants" | ||
} | ||
] | ||
} | ||
] | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
32 changes: 24 additions & 8 deletions
32
apps/vite-native-ts/miniprogram/components/IceButton/index.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
26 changes: 13 additions & 13 deletions
26
apps/vite-native-ts/miniprogram/components/IceButton/index.wxml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,14 +1,14 @@ | ||
<button class="{{customClass}}"> | ||
Primary | ||
</button> | ||
<view class="flex overflow-hidden bg-white border divide-x rounded-lg dark:bg-gray-900 dark:border-gray-700 dark:divide-gray-700 py-6"> | ||
<button class="weapp-reset-button px-4 py-2 text-sm font-medium text-gray-600 transition-colors duration-200 sm:text-base sm:px-6 dark:hover:bg-gray-800 dark:text-gray-300 hover:bg-gray-100"> | ||
Upload | ||
</button> | ||
<button class="weapp-reset-button px-4 py-2 text-sm font-medium text-gray-600 transition-colors duration-200 sm:text-base sm:px-6 dark:hover:bg-gray-800 dark:text-gray-300 hover:bg-gray-100"> | ||
Drift | ||
</button> | ||
<button class="weapp-reset-button px-4 py-2 text-sm font-medium text-gray-600 transition-colors duration-200 sm:text-base sm:px-6 dark:hover:bg-gray-800 dark:text-gray-300 hover:bg-gray-100"> | ||
View | ||
</button> | ||
<view> | ||
<button class="{{mergedClass}}" hover-class="bg-[#123456]">Primary</button> | ||
<view class="mt-4 flex overflow-hidden border divide-x rounded-lg dark:bg-gray-900 dark:border-gray-700 dark:divide-gray-700 py-6"> | ||
<button class="weapp-reset-button px-4 py-2 text-sm font-medium text-gray-600 transition-colors duration-200 sm:text-base sm:px-6 dark:hover:bg-gray-800 dark:text-gray-300 hover:bg-gray-100"> | ||
Upload | ||
</button> | ||
<button class="weapp-reset-button px-4 py-2 text-sm font-medium text-gray-600 transition-colors duration-200 sm:text-base sm:px-6 dark:hover:bg-gray-800 dark:text-gray-300 hover:bg-gray-100"> | ||
Drift | ||
</button> | ||
<button class="weapp-reset-button px-4 py-2 text-sm font-medium text-gray-600 transition-colors duration-200 sm:text-base sm:px-6 dark:hover:bg-gray-800 dark:text-gray-300 hover:bg-gray-100"> | ||
View | ||
</button> | ||
</view> | ||
</view> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,3 @@ | ||
<view class="p-4"> | ||
<IceButton class="bg-[#d72929]" my-class="bg-[orange]"></IceButton> | ||
<IceButton class="bg-[#d72929]" tw-class="bg-[orange]" hover-class="bg-[green]" tw-hover-class="bg-[pink]"></IceButton> | ||
</view> |