-
-
Notifications
You must be signed in to change notification settings - Fork 560
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'main' of https://github.com/lucide-icons/lucide into lu…
…cide-package-aliases
- Loading branch information
Showing
137 changed files
with
4,143 additions
and
1,112 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 |
---|---|---|
|
@@ -10,7 +10,6 @@ on: | |
jobs: | ||
lucide-font: | ||
runs-on: ubuntu-latest | ||
container: ericfennis/lucide-font:latest | ||
steps: | ||
- uses: actions/checkout@v3 | ||
- uses: actions/[email protected] | ||
|
@@ -43,11 +42,11 @@ jobs: | |
- name: Outline svg Icons | ||
run: pnpm build:outline-icons | ||
|
||
- name: Create directory | ||
run: mkdir lucide-font | ||
- name: Install dependencies | ||
run: pnpm install --filter build-font | ||
|
||
- name: Build font | ||
run: fontcustom compile "./outlined" -h -n "lucide" -o ./lucide-font -F | ||
- name: Create font in ./lucide-font | ||
run: pnpm build:font | ||
|
||
- name: "Upload to Artifacts" | ||
uses: actions/upload-artifact@v1 | ||
|
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
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,34 @@ | ||
{ | ||
"colors": { | ||
"surface1": "var(--vp-code-block-bg)", | ||
"surface2": "var(--vp-code-block-bg)", | ||
"surface3": "var(--vp-code-line-highlight-color)", | ||
"clickable": "var(--vp-c-text-2)", | ||
"base": "#323232", | ||
"disabled": "#C5C5C5", | ||
"hover": "var(--vp-c-brand)", | ||
"accent": "var(--vp-c-brand)", | ||
"error": "var(--vp-c-red)", | ||
"errorSurface": "#ffeceb" | ||
}, | ||
"syntax": { | ||
"plain": "var(--vp-code-editor-plain)", | ||
"comment": { | ||
"color": "var(--vp-code-editor-comment)", | ||
"fontStyle": "italic" | ||
}, | ||
"keyword": "var(--vp-code-editor-keyword)", | ||
"tag": "var(--vp-code-editor-tag)", | ||
"punctuation": "var(--vp-code-editor-punctuation)", | ||
"definition": "var(--vp-code-editor-definition)", | ||
"property": "var(--vp-code-editor-property)", | ||
"static": "var(--vp-code-editor-static)", | ||
"string": "var(--vp-code-editor-string)" | ||
}, | ||
"font": { | ||
"body": "var(--vp-font-family-base)", | ||
"mono": "var(--vp-font-family-mono)", | ||
"size": "var(--vp-code-font-size)", | ||
"lineHeight": "var(--vp-code-line-height)" | ||
} | ||
} |
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,4 @@ | ||
# Accessibility | ||
|
||
<!-- Description how you should use svg icons keeping web accessible --> | ||
<!-- See @JanTrichter comment about some information to write this: https://github.com/lucide-icons/lucide/pull/1521#discussion_r1332141390 --> |
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,13 @@ | ||
# Filled Icons | ||
|
||
Fills are officially not supported. | ||
However, all SVG properties are available on all icons. | ||
Fill can still be used and will work fine on certain icons. | ||
|
||
Example with stars: | ||
|
||
<!-- Code Example with stars --> | ||
|
||
## Will Lucide have fills in the future? | ||
|
||
This feature is requested several times and discussion is happening at: [#458](https://github.com/lucide-icons/lucide/discussions/458). |
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,52 @@ | ||
<script setup> | ||
import { Sandpack } from 'sandpack-vue3' | ||
import sandpackTheme from '../../.vitepress/theme/sandpackTheme.json' | ||
import buttonExampleFiles from './examples/button-example/files.ts' | ||
import iconColorExampleFiles from './examples/color-icon/files.ts' | ||
</script> | ||
|
||
# Color | ||
|
||
By default, all icons have the color value: `currentColor`. This keyword uses the element's computed text `color` value to represent the icon color. | ||
|
||
Read more about [ `currentColor` on MDN](https://developer.mozilla.org/en-US/docs/Web/CSS/color_value#currentcolor_keyword). | ||
|
||
## Adjust the color using the `color` prop | ||
|
||
The color can be adjusted by passing the color prop to the element. | ||
|
||
<Sandpack | ||
template="react" | ||
:theme="sandpackTheme" | ||
:files="iconColorExampleFiles" | ||
:customSetup='{ | ||
dependencies: { | ||
"lucide-react": "latest" | ||
} | ||
}' | ||
:options="{ | ||
editorHeight: 295, | ||
editorWidthPercentage: 60, | ||
}" | ||
/> | ||
|
||
## Using parent elements text color value | ||
|
||
Because the color of lucide icons uses `currentColor`, the color of the icon depends on the computed `color` of the element, or it inherits it from its parent. | ||
|
||
For example, if a parent element's color value is `#fff` and one of the children is a lucide icon, the color of the icon will be rendered as `#fff`. This is browser native behavior. | ||
|
||
<Sandpack | ||
template="react" | ||
:theme="sandpackTheme" | ||
:files="buttonExampleFiles" | ||
:customSetup='{ | ||
dependencies: { | ||
"lucide-react": "latest" | ||
} | ||
}' | ||
:options="{ | ||
editorHeight: 320, | ||
editorWidthPercentage: 60, | ||
}" | ||
/> |
14 changes: 14 additions & 0 deletions
14
docs/guide/basics/examples/absolute-stroke-width-icon/App.js
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,14 @@ | ||
import { RollerCoaster } from "lucide-react"; | ||
|
||
function App() { | ||
return ( | ||
<div className="app"> | ||
<RollerCoaster | ||
size={96} | ||
absoluteStrokeWidth={true} | ||
/> | ||
</div> | ||
); | ||
} | ||
|
||
export default App; |
15 changes: 15 additions & 0 deletions
15
docs/guide/basics/examples/absolute-stroke-width-icon/files.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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
import App from './App.js?raw' | ||
import styles from '../styles.css?raw' | ||
|
||
const files = { | ||
'App.js': { | ||
code: App, | ||
active: true, | ||
}, | ||
'styles.css': { | ||
code:styles, | ||
hidden: true | ||
}, | ||
} | ||
|
||
export default files |
Oops, something went wrong.