Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Feat]: Support different themes including dark theme #48

Merged
merged 2 commits into from Feb 27, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
5 changes: 4 additions & 1 deletion README.md
@@ -1,5 +1,8 @@
<!-- <p align="center"><a href="#"><img width=60% alt="" src="https://docs-us.oss-us-west-1.aliyuncs.com/img/pygwalker/screenshot-top-img.png"></a></p> -->
<p align="center"><a href="https://github.com/Kanaries/pygwalker"><img width=100% alt="" src="https://docs-us.oss-us-west-1.aliyuncs.com/img/pygwalker/frontpage-rendered.png"></a></p>
<!-- <p align="center"><a href="https://github.com/Kanaries/pygwalker"><img width=100% alt="" src="https://docs-us.oss-us-west-1.aliyuncs.com/img/pygwalker/frontpage-rendered.png"></a></p> -->

<p align="center"><a href="https://github.com/Kanaries/pygwalker"><img width=100% alt="" src="https://user-images.githubusercontent.com/8137814/221666598-e06ec92b-50e9-4094-8312-ba178c7d6129.png"></a></p>

<h2 align="center">PyGWalker: A Python Library for Exploratory Data Analysis with Visualization</h2>

<p align="center">
Expand Down
2 changes: 1 addition & 1 deletion graphic-walker
Submodule graphic-walker updated 60 files
+6 −1 README.md
+1 −0 packages/graphic-walker/package.json
+8 −5 packages/graphic-walker/src/App.tsx
+1 −0 packages/graphic-walker/src/components/button/base.ts
+6 −2 packages/graphic-walker/src/components/button/default.tsx
+17 −0 packages/graphic-walker/src/components/button/defaultMini.tsx
+6 −2 packages/graphic-walker/src/components/button/primary.tsx
+21 −0 packages/graphic-walker/src/components/button/primaryMini.tsx
+4 −1 packages/graphic-walker/src/components/callout.tsx
+4 −2 packages/graphic-walker/src/components/clickMenu.tsx
+9 −0 packages/graphic-walker/src/components/container.tsx
+42 −52 packages/graphic-walker/src/components/dataTable/index.tsx
+4 −4 packages/graphic-walker/src/components/dataTable/pagination.tsx
+1 −1 packages/graphic-walker/src/components/dataTypeIcon.tsx
+64 −0 packages/graphic-walker/src/components/dropdownContext/index.tsx
+92 −0 packages/graphic-walker/src/components/dropdownSelect/index.tsx
+26 −14 packages/graphic-walker/src/components/modal.tsx
+4 −4 packages/graphic-walker/src/components/tabs/defaultTab.tsx
+5 −5 packages/graphic-walker/src/components/tabs/editableTab.tsx
+18 −1 packages/graphic-walker/src/components/toolbar/components.tsx
+5 −0 packages/graphic-walker/src/components/toolbar/index.tsx
+6 −1 packages/graphic-walker/src/components/toolbar/toolbar-button.tsx
+4 −0 packages/graphic-walker/src/components/toolbar/toolbar-item.tsx
+21 −4 packages/graphic-walker/src/components/toolbar/toolbar-select-button.tsx
+6 −1 packages/graphic-walker/src/components/toolbar/toolbar-toggle-button.tsx
+4 −1 packages/graphic-walker/src/components/tooltip.tsx
+5 −3 packages/graphic-walker/src/dataSource/dataSelection/csvData.tsx
+0 −8 packages/graphic-walker/src/dataSource/dataSelection/gwFile.tsx
+1 −2 packages/graphic-walker/src/dataSource/dataSelection/index.tsx
+2 −3 packages/graphic-walker/src/dataSource/dataSelection/publicData.tsx
+81 −61 packages/graphic-walker/src/dataSource/index.tsx
+3 −1 packages/graphic-walker/src/fields/aestheticFields.tsx
+21 −2 packages/graphic-walker/src/fields/components.tsx
+43 −35 packages/graphic-walker/src/fields/datasetFields/dimFields.tsx
+2 −2 packages/graphic-walker/src/fields/datasetFields/index.tsx
+73 −47 packages/graphic-walker/src/fields/datasetFields/meaFields.tsx
+92 −0 packages/graphic-walker/src/fields/encodeFields/singleEncodeDropDown.tsx
+45 −0 packages/graphic-walker/src/fields/encodeFields/singleEncodeEditor.tsx
+2 −1 packages/graphic-walker/src/fields/filterField/filterEditDialog.tsx
+1 −1 packages/graphic-walker/src/fields/filterField/filterPill.tsx
+1 −1 packages/graphic-walker/src/fields/filterField/slider.tsx
+11 −21 packages/graphic-walker/src/fields/filterField/tabs.tsx
+65 −35 packages/graphic-walker/src/fields/obComponents/obPill.tsx
+13 −0 packages/graphic-walker/src/index.css
+24 −23 packages/graphic-walker/src/insightBoard/index.tsx
+7 −0 packages/graphic-walker/src/insightBoard/radioGroupButtons.tsx
+1 −0 packages/graphic-walker/src/interfaces.ts
+4 −3 packages/graphic-walker/src/locales/en-US.json
+2 −1 packages/graphic-walker/src/locales/zh-CN.json
+1 −1 packages/graphic-walker/src/main.tsx
+2 −1 packages/graphic-walker/src/renderer/index.tsx
+16 −0 packages/graphic-walker/src/store/visualSpecStore.ts
+19 −0 packages/graphic-walker/src/utils/index.ts
+26 −0 packages/graphic-walker/src/utils/media.ts
+2 −1 packages/graphic-walker/src/utils/normalization.ts
+17 −4 packages/graphic-walker/src/vis/react-vega.tsx
+126 −0 packages/graphic-walker/src/vis/theme.ts
+24 −8 packages/graphic-walker/src/visualSettings/index.tsx
+2 −2 packages/graphic-walker/tailwind.config.js
+614 −722 yarn.lock
2 changes: 0 additions & 2 deletions pygwalker/gwalker.py
Expand Up @@ -12,7 +12,6 @@ def to_html(df: pd.DataFrame, gid: tp.Union[int, str]=None, **kwargs):
hideDataSourceConfig (bool, optional): Hide DataSource import and export button (True) or not (False). Default to True
"""
global global_gid
gid = kwargs.get('gid', None)
if gid is None:
gid = global_gid
global_gid += 1
Expand All @@ -30,7 +29,6 @@ def walk(df: pd.DataFrame, gid: tp.Union[int, str]=None, **kwargs):
return_html (bool, optional): Directly return a html string. Defaults to False.
"""
global global_gid
gid = kwargs.get('gid', None)
return_html = kwargs.get('return_html', False)
if gid is None:
gid = global_gid
Expand Down
556 changes: 315 additions & 241 deletions pygwalker/templates/graphic-walker.iife.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion pygwalker/templates/walk.js
@@ -1,6 +1,6 @@
try{
var gw_id = "gwalker-{{ gwalker.id }}";
var props = {{ gwalker.props }};
console.log(props, gw_id);
GraphicWalker.GWalker(props, gw_id);
try{
}catch(e){ console.error(e); }
2 changes: 2 additions & 0 deletions pygwalker/utils/gwalker_props.py
Expand Up @@ -51,5 +51,7 @@ def get_props(df: pd.DataFrame, **kwargs):
'rawFields': raw_fields(df),
'hideDataSourceConfig': kwargs.get('hideDataSourceConfig', True),
'fieldkeyGuard': False,
'themeKey': 'g2',
**kwargs,
}
return props
2 changes: 1 addition & 1 deletion pyproject.toml
@@ -1,6 +1,6 @@
[tool.poetry]
name = "pygwalker"
version = "0.1.4.3"
version = "0.1.4.4"
description = "pygwalker: Combining Jupyter Notebook with a Tableau-like UI"
authors = ["Asm.Def <woojson@zju.edu.cn>"]
license = 'Apache License 2.0'
Expand Down
471 changes: 227 additions & 244 deletions tests/develop.ipynb

Large diffs are not rendered by default.

589 changes: 337 additions & 252 deletions tests/main.ipynb

Large diffs are not rendered by default.