jac-client 0.2.10__py3-none-any.whl → 0.2.12__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.
Files changed (85) hide show
  1. jac_client/examples/all-in-one/button.jac +4 -3
  2. jac_client/examples/all-in-one/components/CategoryFilter.jac +36 -24
  3. jac_client/examples/all-in-one/components/Header.jac +12 -8
  4. jac_client/examples/all-in-one/components/ProfitOverview.jac +49 -35
  5. jac_client/examples/all-in-one/components/Summary.jac +59 -36
  6. jac_client/examples/all-in-one/components/TransactionForm.jac +142 -112
  7. jac_client/examples/all-in-one/components/TransactionItem.jac +37 -30
  8. jac_client/examples/all-in-one/components/TransactionList.jac +33 -26
  9. jac_client/examples/all-in-one/components/button.jac +4 -3
  10. jac_client/examples/all-in-one/components/navigation.jac +111 -117
  11. jac_client/examples/all-in-one/constants/categories.jac +23 -24
  12. jac_client/examples/all-in-one/constants/clients.jac +7 -8
  13. jac_client/examples/all-in-one/context/BudgetContext.jac +9 -6
  14. jac_client/examples/all-in-one/hooks/useBudget.jac +18 -12
  15. jac_client/examples/all-in-one/hooks/useLocalStorage.jac +14 -13
  16. jac_client/examples/all-in-one/main.jac +340 -371
  17. jac_client/examples/all-in-one/pages/BudgetPlanner.jac +19 -12
  18. jac_client/examples/all-in-one/pages/FeaturesTest.jac +31 -15
  19. jac_client/examples/all-in-one/pages/LandingPage.jac +113 -90
  20. jac_client/examples/all-in-one/pages/budget_planner_ui.cl.jac +34 -39
  21. jac_client/examples/all-in-one/pages/features_test_ui.cl.jac +464 -352
  22. jac_client/examples/all-in-one/pages/loginPage.jac +114 -119
  23. jac_client/examples/all-in-one/pages/nestedDemo.jac +43 -50
  24. jac_client/examples/all-in-one/pages/notFound.jac +14 -15
  25. jac_client/examples/all-in-one/pages/signupPage.jac +113 -119
  26. jac_client/examples/all-in-one/utils/formatters.jac +5 -8
  27. jac_client/examples/asset-serving/css-with-image/main.jac +77 -73
  28. jac_client/examples/asset-serving/image-asset/main.jac +47 -46
  29. jac_client/examples/asset-serving/import-alias/main.jac +93 -95
  30. jac_client/examples/basic/main.jac +17 -15
  31. jac_client/examples/basic-auth/main.jac +246 -254
  32. jac_client/examples/basic-auth-with-router/main.jac +272 -285
  33. jac_client/examples/basic-full-stack/main.jac +245 -242
  34. jac_client/examples/css-styling/js-styling/main.jac +41 -62
  35. jac_client/examples/css-styling/material-ui/main.jac +90 -90
  36. jac_client/examples/css-styling/pure-css/main.jac +35 -44
  37. jac_client/examples/css-styling/sass-example/main.jac +35 -44
  38. jac_client/examples/css-styling/styled-components/main.jac +38 -47
  39. jac_client/examples/css-styling/tailwind-example/main.jac +54 -43
  40. jac_client/examples/full-stack-with-auth/main.jac +407 -433
  41. jac_client/examples/little-x/main.jac +306 -344
  42. jac_client/examples/little-x/src/submit-button.jac +15 -14
  43. jac_client/examples/nested-folders/nested-advance/main.jac +18 -27
  44. jac_client/examples/nested-folders/nested-advance/src/ButtonRoot.jac +4 -6
  45. jac_client/examples/nested-folders/nested-advance/src/level1/ButtonSecondL.jac +9 -13
  46. jac_client/examples/nested-folders/nested-advance/src/level1/Card.jac +29 -32
  47. jac_client/examples/nested-folders/nested-advance/src/level1/level2/ButtonThirdL.jac +12 -18
  48. jac_client/examples/nested-folders/nested-basic/main.jac +7 -5
  49. jac_client/examples/nested-folders/nested-basic/src/button.jac +4 -3
  50. jac_client/examples/nested-folders/nested-basic/src/components/button.jac +4 -3
  51. jac_client/examples/ts-support/main.jac +26 -26
  52. jac_client/examples/with-router/main.jac +186 -223
  53. jac_client/plugin/client_runtime.cl.jac +5 -3
  54. jac_client/plugin/impl/client_runtime.impl.jac +1 -1
  55. jac_client/plugin/plugin_config.jac +53 -99
  56. jac_client/plugin/src/__init__.jac +0 -2
  57. jac_client/plugin/src/compiler.jac +0 -1
  58. jac_client/plugin/src/impl/compiler.impl.jac +49 -17
  59. jac_client/plugin/src/impl/jac_to_js.impl.jac +5 -1
  60. jac_client/plugin/src/impl/package_installer.impl.jac +20 -20
  61. jac_client/plugin/src/impl/vite_bundler.impl.jac +146 -84
  62. jac_client/plugin/src/targets/impl/desktop_target.impl.jac +54 -41
  63. jac_client/plugin/utils/__init__.jac +3 -0
  64. jac_client/plugin/utils/bun_installer.jac +16 -0
  65. jac_client/plugin/utils/client_deps.jac +14 -0
  66. jac_client/plugin/utils/impl/bun_installer.impl.jac +99 -0
  67. jac_client/plugin/utils/impl/client_deps.impl.jac +73 -0
  68. jac_client/templates/client.jacpack +0 -4
  69. jac_client/templates/fullstack.jacpack +1 -5
  70. jac_client/tests/conftest.py +56 -41
  71. jac_client/tests/fixtures/spawn_test/app.jac +49 -52
  72. jac_client/tests/fixtures/with-ts/app.jac +27 -27
  73. jac_client/tests/test_cli.py +71 -6
  74. jac_client/tests/test_helpers.py +11 -18
  75. jac_client/tests/test_it.py +1 -1
  76. {jac_client-0.2.10.dist-info → jac_client-0.2.12.dist-info}/METADATA +5 -5
  77. jac_client-0.2.12.dist-info/RECORD +115 -0
  78. {jac_client-0.2.10.dist-info → jac_client-0.2.12.dist-info}/WHEEL +1 -1
  79. jac_client/plugin/src/babel_processor.jac +0 -18
  80. jac_client/plugin/src/impl/babel_processor.impl.jac +0 -89
  81. jac_client/plugin/utils/impl/node_installer.impl.jac +0 -249
  82. jac_client/plugin/utils/node_installer.jac +0 -41
  83. jac_client-0.2.10.dist-info/RECORD +0 -115
  84. {jac_client-0.2.10.dist-info → jac_client-0.2.12.dist-info}/entry_points.txt +0 -0
  85. {jac_client-0.2.10.dist-info → jac_client-0.2.12.dist-info}/top_level.txt +0 -0
@@ -1,16 +1,17 @@
1
1
  cl def:pub SubmitButton -> any {
2
- return <button
3
- type="submit"
4
- style={{
5
- "width": "100%",
6
- "padding": "10px",
7
- "backgroundColor": "#1da1f2",
8
- "color": "white",
9
- "border": "none",
10
- "borderRadius": "4px",
11
- "cursor": "pointer"
12
- }}
13
- >
14
- Sign Up
15
- </button>;
2
+ return
3
+ <button
4
+ type="submit"
5
+ style={{
6
+ "width": "100%",
7
+ "padding": "10px",
8
+ "backgroundColor": "#1da1f2",
9
+ "color": "white",
10
+ "border": "none",
11
+ "borderRadius": "4px",
12
+ "cursor": "pointer"
13
+ }}
14
+ >
15
+ Sign Up
16
+ </button>;
16
17
  }
@@ -5,31 +5,22 @@ cl import from .level1.level2.ButtonThirdL { ButtonThirdL }
5
5
  cl import from .level1.Card { Card }
6
6
 
7
7
  cl def:pub app -> any {
8
- return <div
9
- style={{padding: "20px"}}
10
- >
11
- <h1>
12
- Nested Folder Levels Demo
13
- </h1>
14
- <div
15
- style={{margin: "10px 0"}}
16
- >
17
- <ButtonRoot />
18
- </div>
19
- <div
20
- style={{margin: "10px 0"}}
21
- >
22
- <ButtonSecondL />
23
- </div>
24
- <div
25
- style={{margin: "10px 0"}}
26
- >
27
- <ButtonThirdL />
28
- </div>
29
- <div
30
- style={{margin: "10px 0"}}
31
- >
32
- <Card />
33
- </div>
34
- </div>;
8
+ return
9
+ <div style={{padding: "20px"}}>
10
+ <h1>
11
+ Nested Folder Levels Demo
12
+ </h1>
13
+ <div style={{margin: "10px 0"}}>
14
+ <ButtonRoot />
15
+ </div>
16
+ <div style={{margin: "10px 0"}}>
17
+ <ButtonSecondL />
18
+ </div>
19
+ <div style={{margin: "10px 0"}}>
20
+ <ButtonThirdL />
21
+ </div>
22
+ <div style={{margin: "10px 0"}}>
23
+ <Card />
24
+ </div>
25
+ </div>;
35
26
  }
@@ -2,10 +2,8 @@
2
2
  cl import from antd { Button }
3
3
 
4
4
  cl def:pub ButtonRoot -> any {
5
- return <Button
6
- type="primary"
7
- size="large"
8
- >
9
- Root Level Button
10
- </Button>;
5
+ return
6
+ <Button type="primary" size="large">
7
+ Root Level Button
8
+ </Button>;
11
9
  }
@@ -3,17 +3,13 @@ cl import from antd { Button }
3
3
  cl import from ..ButtonRoot { ButtonRoot }
4
4
 
5
5
  cl def:pub ButtonSecondL -> any {
6
- return <div>
7
- <Button
8
- type="default"
9
- size="large"
10
- >
11
- Second Level Button (imports from root)
12
- </Button>
13
- <div
14
- style={{marginTop: "10px"}}
15
- >
16
- <ButtonRoot />
17
- </div>
18
- </div>;
6
+ return
7
+ <div>
8
+ <Button type="default" size="large">
9
+ Second Level Button (imports from root)
10
+ </Button>
11
+ <div style={{marginTop: "10px"}}>
12
+ <ButtonRoot />
13
+ </div>
14
+ </div>;
19
15
  }
@@ -6,38 +6,35 @@ cl import from ..ButtonRoot {
6
6
  cl import from .level2.ButtonThirdL { ButtonThirdL }
7
7
 
8
8
  cl def:pub Card -> any {
9
- return <div
10
- style={{
11
- border: "2px solid #007bff",
12
- borderRadius: "8px",
13
- padding: "20px",
14
- margin: "10px 0",
15
- backgroundColor: "#f8f9fa"
16
- }}
17
- >
18
- <h3>
19
- Card Component (Second Level)
20
- </h3>
21
- <p>
22
- This card imports from:
23
- </p>
24
- <ul>
25
- <li>
26
- Root level: ButtonRoot (using ..)
27
- </li>
28
- <li>
29
- Third level: ButtonThirdL (using .level2)
30
- </li>
31
- </ul>
9
+ return
32
10
  <div
33
- style={{marginTop: "15px"}}
11
+ style={{
12
+ border: "2px solid #007bff",
13
+ borderRadius: "8px",
14
+ padding: "20px",
15
+ margin: "10px 0",
16
+ backgroundColor: "#f8f9fa"
17
+ }}
34
18
  >
35
- <ButtonRoot />
36
- </div>
37
- <div
38
- style={{marginTop: "10px"}}
39
- >
40
- <ButtonThirdL />
41
- </div>
42
- </div>;
19
+ <h3>
20
+ Card Component (Second Level)
21
+ </h3>
22
+ <p>
23
+ This card imports from:
24
+ </p>
25
+ <ul>
26
+ <li>
27
+ Root level: ButtonRoot (using ..)
28
+ </li>
29
+ <li>
30
+ Third level: ButtonThirdL (using .level2)
31
+ </li>
32
+ </ul>
33
+ <div style={{marginTop: "15px"}}>
34
+ <ButtonRoot />
35
+ </div>
36
+ <div style={{marginTop: "10px"}}>
37
+ <ButtonThirdL />
38
+ </div>
39
+ </div>;
43
40
  }
@@ -4,22 +4,16 @@ cl import from ...ButtonRoot { ButtonRoot }
4
4
  cl import from ..ButtonSecondL { ButtonSecondL }
5
5
 
6
6
  cl def:pub ButtonThirdL -> any {
7
- return <div>
8
- <Button
9
- type="dashed"
10
- size="large"
11
- >
12
- Third Level Button (imports from root and second level)
13
- </Button>
14
- <div
15
- style={{marginTop: "10px"}}
16
- >
17
- <ButtonRoot />
18
- </div>
19
- <div
20
- style={{marginTop: "10px"}}
21
- >
22
- <ButtonSecondL />
23
- </div>
24
- </div>;
7
+ return
8
+ <div>
9
+ <Button type="dashed" size="large">
10
+ Third Level Button (imports from root and second level)
11
+ </Button>
12
+ <div style={{marginTop: "10px"}}>
13
+ <ButtonRoot />
14
+ </div>
15
+ <div style={{marginTop: "10px"}}>
16
+ <ButtonSecondL />
17
+ </div>
18
+ </div>;
25
19
  }
@@ -2,12 +2,14 @@ cl import from .components.button { CustomButton }
2
2
  cl import from .button { CustomButtonRoot }
3
3
 
4
4
  cl def RelativeImport -> any {
5
- return <div>
6
- <CustomButton />
7
- <CustomButtonRoot />
8
- </div>;
5
+ return
6
+ <div>
7
+ <CustomButton />
8
+ <CustomButtonRoot />
9
+ </div>;
9
10
  }
10
11
 
11
12
  cl def:pub app -> any {
12
- return <RelativeImport />;
13
+ return
14
+ <RelativeImport />;
13
15
  }
@@ -1,7 +1,8 @@
1
1
  cl import from antd { Button }
2
2
 
3
3
  cl def:pub CustomButtonRoot -> any {
4
- return <Button>
5
- Click Me
6
- </Button>;
4
+ return
5
+ <Button>
6
+ Click Me
7
+ </Button>;
7
8
  }
@@ -1,7 +1,8 @@
1
1
  cl import from antd { Button }
2
2
 
3
3
  cl def:pub CustomButton -> any {
4
- return <Button>
5
- Click Me
6
- </Button>;
4
+ return
5
+ <Button>
6
+ Click Me
7
+ </Button>;
7
8
  }
@@ -1,35 +1,35 @@
1
1
 
2
2
  # Pages
3
- cl import from react { useEffect }
4
3
  cl import from ".components/Button.tsx" { Button }
5
4
 
6
5
  cl {
7
6
  def:pub app -> any {
8
7
  has count: int = 0;
9
- useEffect(lambda -> None{ console.log("Count: ", count);} , [count]);
10
- return <div
11
- style={{padding: "2rem", fontFamily: "Arial, sans-serif"}}
12
- >
13
- <h1>
14
- Hello, World!
15
- </h1>
16
- <p>
17
- Count: {count}
18
- </p>
19
- <div
20
- style={{display: "flex", gap: "1rem", marginTop: "1rem"}}
21
- >
22
- <Button
23
- label="Increment"
24
- onClick={lambda -> None{ count = count + 1;} }
25
- variant="primary"
26
- />
27
- <Button
28
- label="Reset"
29
- onClick={lambda -> None{ count = 0;} }
30
- variant="secondary"
31
- />
32
- </div>
33
- </div>;
8
+
9
+ can with count entry {
10
+ console.log("Count: ", count);
11
+ }
12
+
13
+ return
14
+ <div style={{padding: "2rem", fontFamily: "Arial, sans-serif"}}>
15
+ <h1>
16
+ Hello, World!
17
+ </h1>
18
+ <p>
19
+ Count: {count}
20
+ </p>
21
+ <div style={{display: "flex", gap: "1rem", marginTop: "1rem"}}>
22
+ <Button
23
+ label="Increment"
24
+ onClick={lambda -> None { count = count + 1;}}
25
+ variant="primary"
26
+ />
27
+ <Button
28
+ label="Reset"
29
+ onClick={lambda -> None { count = 0;}}
30
+ variant="secondary"
31
+ />
32
+ </div>
33
+ </div>;
34
34
  }
35
35
  }