Skip to content

Commit c01ba74

Browse files
committed
#30 스타일시트에 관한 readme 내용추가
1 parent 3ea6f07 commit c01ba74

File tree

2 files changed

+22
-1
lines changed

2 files changed

+22
-1
lines changed

README.md

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -270,6 +270,27 @@ wrap.addEventListener('context', ({ detail: { body, node, type, isRoot, $ } }) =
270270
- `@redgoose/json-editor/lib/umd`: 코어 라이브러리 UMD
271271

272272

273+
## Custom style
274+
275+
에디터의 디자인을 수정할 수 있는 요소들을 변수화 시켰습니다.
276+
다음과 같이 외부 영역에서 에디터 스타일을 커스터마이즈 할 수 있습니다.
277+
278+
```css
279+
.editor {
280+
--json-editor-color-base: red;
281+
--json-editor-color-focus: blue;
282+
}
283+
@media (prefers-color-scheme: dark) {
284+
.editor {
285+
--json-editor-color-base: green;
286+
--json-editor-color-focus: yellow;
287+
}
288+
}
289+
```
290+
291+
[main.scss](https://github.com/redgoose-dev/json-editor/blob/main/src/json-editor/assets/main.scss) 파일의 코드를 참고하여 직접 스타일을 편집할 수 있습니다.
292+
293+
273294
## Developing a wrapper
274295

275296
`JSON Editor` 에디터를 `web component`, `react`, `vue`, `svelte` 같은 환경에서 사용할 수 있도록 컴포넌트를 래핑할 수 있습니다.

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
"name": "@redgoose/json-editor",
33
"description": "Easy editing JSON data",
44
"author": "redgoose <[email protected]>",
5-
"version": "1.0.4",
5+
"version": "1.0.5",
66
"keywords": [ "json", "editor", "library", "tool" ],
77
"license": "MIT",
88
"main": "./lib/json-editor.js",

0 commit comments

Comments
 (0)