sweatstack 0.14.7__py3-none-any.whl → 0.16.0__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
sweatstack/streamlit.py CHANGED
@@ -40,13 +40,42 @@ class StreamlitAuth:
40
40
  st.rerun()
41
41
 
42
42
  def _show_sweatstack_login(self):
43
- st.link_button("Login", self._get_authorization_url_implicit())
43
+ authorization_url = self._get_authorization_url()
44
+ st.markdown(
45
+ f"""
46
+ <style>
47
+ .animated-button {{
48
+ }}
49
+ .animated-button:hover {{
50
+ transform: scale(1.05);
51
+ }}
52
+ .animated-button:active {{
53
+ transform: scale(1);
54
+ }}
55
+ </style>
56
+ <a href="{authorization_url}"
57
+ target="_self"
58
+ class="animated-button"
59
+ style="display: inline-block;
60
+ padding: 10px 20px;
61
+ background-color: #EF2B2D;
62
+ color: white;
63
+ text-decoration: none;
64
+ border-radius: 6px;
65
+ border: none;
66
+ transition: all 0.3s ease;
67
+ cursor: pointer;"
68
+ >Login with SweatStack</a>
69
+ """,
70
+ unsafe_allow_html=True,
71
+ )
44
72
 
45
- def _get_authorization_url_implicit(self):
73
+ def _get_authorization_url(self):
46
74
  params = {
47
75
  "client_id": self.client_id,
48
76
  "redirect_uri": self.redirect_uri,
49
77
  "scope": "data:read",
78
+ "prompt": "none",
50
79
  }
51
80
  path = "/oauth/authorize"
52
81
  authorization_url = urllib.parse.urljoin(DEFAULT_URL, path + "?" + urllib.parse.urlencode(params))
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: sweatstack
3
- Version: 0.14.7
3
+ Version: 0.16.0
4
4
  Summary: The official Python client for SweatStack
5
5
  Author-email: Aart Goossens <aart@gssns.io>
6
6
  Requires-Python: >=3.12
@@ -7,10 +7,10 @@ sweatstack/jupyterlab_oauth2_startup.py,sha256=eZ6xi0Sa4hO4vUanimq0SqjduHtiywCUR
7
7
  sweatstack/openapi_schemas.py,sha256=vtYHa6A0kADFbd_jK1O7Kbn8YkbPfzaIwsRDDYjYeSA,13038
8
8
  sweatstack/py.typed,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
9
9
  sweatstack/schemas.py,sha256=CdkeV6IRmIuvxae7C5dz-hVlb6hkzEYfqKHHgVJprmY,90
10
- sweatstack/streamlit.py,sha256=_9FOzEADveEIMytNIdQWhboyq6Pvi0E9e1yZhhd85Cg,3455
10
+ sweatstack/streamlit.py,sha256=4zA9g0MVycQM_-yAf_CULXmRiGkT9vHEH1d4U56sM20,4392
11
11
  sweatstack/sweatshell.py,sha256=MYLNcWbOdceqKJ3S0Pe8dwHXEeYsGJNjQoYUXpMTftA,333
12
12
  sweatstack/utils.py,sha256=HtR1NNCKus59vfgfaCSFS-tHA11mtdcuUx5lS6ZX58g,1773
13
- sweatstack-0.14.7.dist-info/METADATA,sha256=C_CcZ6QIq5qzI19zsSYy0BpEk6C9vRmZ8CJ6Vi2vkcE,2966
14
- sweatstack-0.14.7.dist-info/WHEEL,sha256=qtCwoSJWgHk21S1Kb4ihdzI2rlJ1ZKaIurTj_ngOhyQ,87
15
- sweatstack-0.14.7.dist-info/entry_points.txt,sha256=kCzOUQI3dqbTpEYqtgYDeiKFaqaA7BMlV6D24BMzCFU,208
16
- sweatstack-0.14.7.dist-info/RECORD,,
13
+ sweatstack-0.16.0.dist-info/METADATA,sha256=jEFUwzmBc67PgtBIy8s68yAuA1423Jb-NGifMyTxrlE,2966
14
+ sweatstack-0.16.0.dist-info/WHEEL,sha256=qtCwoSJWgHk21S1Kb4ihdzI2rlJ1ZKaIurTj_ngOhyQ,87
15
+ sweatstack-0.16.0.dist-info/entry_points.txt,sha256=kCzOUQI3dqbTpEYqtgYDeiKFaqaA7BMlV6D24BMzCFU,208
16
+ sweatstack-0.16.0.dist-info/RECORD,,