@rangular-framework/cli 0.0.0-stage → 1.0.1

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 (36) hide show
  1. package/dist/cli/src/cli.js +1229 -0
  2. package/dist/compiler/src/catalog.js +198 -0
  3. package/dist/compiler/src/class/formInit.js +370 -0
  4. package/dist/compiler/src/class/parseComponent.js +430 -0
  5. package/dist/compiler/src/class/parseDirective.js +227 -0
  6. package/dist/compiler/src/class/parseRoutes.js +163 -0
  7. package/dist/compiler/src/codegen/generate.js +3466 -0
  8. package/dist/compiler/src/codegen/methods.js +975 -0
  9. package/dist/compiler/src/codegen/sourceMap.js +77 -0
  10. package/dist/compiler/src/compile.js +775 -0
  11. package/dist/compiler/src/diagnostics.js +113 -0
  12. package/dist/compiler/src/doctor.js +144 -0
  13. package/dist/compiler/src/fix.js +44 -0
  14. package/dist/compiler/src/index.js +38 -0
  15. package/dist/compiler/src/preview/renderPreview.js +7158 -0
  16. package/dist/compiler/src/preview/styleSnapshot.js +268 -0
  17. package/dist/compiler/src/propTable.js +107 -0
  18. package/dist/compiler/src/style/css.js +161 -0
  19. package/dist/compiler/src/template/ast.js +19 -0
  20. package/dist/compiler/src/template/evaluate.js +151 -0
  21. package/dist/compiler/src/template/expr.js +360 -0
  22. package/dist/compiler/src/template/forms.js +80 -0
  23. package/dist/compiler/src/template/literal.js +248 -0
  24. package/dist/compiler/src/template/parser.js +230 -0
  25. package/dist/compiler/src/template/pipes.js +225 -0
  26. package/dist/compiler/src/template/printAst.js +38 -0
  27. package/dist/compiler/src/template/structural.js +51 -0
  28. package/dist/runtime/src/index.js +1197 -0
  29. package/dist/ui/src/chart.js +196 -0
  30. package/dist/ui/src/datetime.js +240 -0
  31. package/dist/ui/src/icons.js +310 -0
  32. package/dist/ui/src/mask.js +103 -0
  33. package/dist/ui/src/palette.js +141 -0
  34. package/dist/ui/src/tokens.js +173 -0
  35. package/package.json +28 -4
  36. package/README.md +0 -3
@@ -0,0 +1,173 @@
1
+ "use strict";
2
+ /**
3
+ * Rangular Material design tokens, pure TypeScript, no react-native imports.
4
+ * Every visual value in a generated app comes from here; generated code never
5
+ * contains magic numbers. See docs/UI_POLISH.md.
6
+ */
7
+ Object.defineProperty(exports, "__esModule", { value: true });
8
+ exports.themes = exports.elevation = exports.colours = exports.typeScale = exports.radiusScale = exports.radius = exports.spacingScale = exports.spacing = void 0;
9
+ exports.theme = theme;
10
+ exports.spacing = {
11
+ xs: 4, sm: 8, md: 12, lg: 16, xl: 20, xxl: 24, xxxl: 32,
12
+ };
13
+ exports.spacingScale = [4, 8, 12, 16, 20, 24, 32];
14
+ exports.radius = {
15
+ sm: 8, md: 12, lg: 16, xl: 20, full: 9999,
16
+ };
17
+ exports.radiusScale = [8, 12, 16, 20, 9999];
18
+ exports.typeScale = {
19
+ caption: { fontSize: 12, lineHeight: 16, fontWeight: '400' },
20
+ body: { fontSize: 14, lineHeight: 20, fontWeight: '400' },
21
+ bodyLarge: { fontSize: 16, lineHeight: 24, fontWeight: '400' },
22
+ label: { fontSize: 14, lineHeight: 20, fontWeight: '600' },
23
+ title: { fontSize: 20, lineHeight: 28, fontWeight: '600' },
24
+ heading: { fontSize: 24, lineHeight: 32, fontWeight: '700' },
25
+ display: { fontSize: 32, lineHeight: 40, fontWeight: '700' },
26
+ };
27
+ exports.colours = {
28
+ light: {
29
+ primary: '#0b57d0',
30
+ onPrimary: '#ffffff',
31
+ primaryContainer: '#e8f0fe',
32
+ onPrimaryContainer: '#041e49',
33
+ secondary: '#00639b',
34
+ secondaryContainer: '#cde6ff',
35
+ onSecondaryContainer: '#001d32',
36
+ accent: '#0b57d0',
37
+ background: '#ffffff',
38
+ surface: '#ffffff',
39
+ surfaceVariant: '#f0f4f9',
40
+ onSurface: '#1f1f1f',
41
+ onSurfaceVariant: '#5f6368',
42
+ text: '#1f1f1f',
43
+ textMuted: '#5f6368',
44
+ error: '#b3261e',
45
+ onError: '#ffffff',
46
+ danger: '#b3261e',
47
+ success: '#34a853',
48
+ border: '#dadce0',
49
+ outline: '#747775',
50
+ scrim: '#000000',
51
+ avatar: '#7b1fa2',
52
+ onAvatar: '#ffffff',
53
+ codeSurface: '#1e1e1e',
54
+ codeText: '#d4d4d4',
55
+ toastSurface: '#000000d9',
56
+ toastText: '#f1f3f4',
57
+ toastAction: '#a8c7fa',
58
+ gradientFrom: '#0849ad',
59
+ gradientVia: '#0b57d0',
60
+ gradientTo: '#4285f4',
61
+ washFrom: '#dde7f5',
62
+ washVia: '#e9eff8',
63
+ washTo: '#fbfcfe',
64
+ primaryDeep: '#0849ad',
65
+ onGradient: '#ffffff',
66
+ primaryHi: '#6ea8ff',
67
+ dangerHi: '#f08379',
68
+ dangerVia: '#d93025',
69
+ dangerDeep: '#a50e0e',
70
+ warningHi: '#fbbc04',
71
+ warningVia: '#f29900',
72
+ warningDeep: '#e37400',
73
+ warningText: '#b06000',
74
+ successHi: '#5fbf77',
75
+ successVia: '#34a853',
76
+ successDeep: '#20713a',
77
+ neutralHi: '#bdc1c6',
78
+ neutralVia: '#80868b',
79
+ neutralDeep: '#5f6368',
80
+ secondaryHi: '#ffffff',
81
+ secondaryVia: '#eef3fd',
82
+ secondaryDeep: '#dbe7fc',
83
+ secondaryBorder: '#c6dafc',
84
+ secondaryLabel: '#0b57d0',
85
+ disabledHi: '#eef0f2',
86
+ disabledVia: '#e3e5e8',
87
+ disabledDeep: '#dadce0',
88
+ },
89
+ dark: {
90
+ primary: '#a8c7fa',
91
+ onPrimary: '#062e6f',
92
+ primaryContainer: '#004a77',
93
+ onPrimaryContainer: '#d3e3fd',
94
+ secondary: '#8ecbf2',
95
+ secondaryContainer: '#004b70',
96
+ onSecondaryContainer: '#cde6ff',
97
+ accent: '#a8c7fa',
98
+ background: '#131314',
99
+ surface: '#1e1f20',
100
+ surfaceVariant: '#282a2c',
101
+ onSurface: '#e3e3e3',
102
+ onSurfaceVariant: '#9aa0a6',
103
+ text: '#e3e3e3',
104
+ textMuted: '#9aa0a6',
105
+ error: '#f2b8b5',
106
+ onError: '#601410',
107
+ danger: '#f2b8b5',
108
+ success: '#81c995',
109
+ border: '#444746',
110
+ outline: '#8e918f',
111
+ scrim: '#000000',
112
+ avatar: '#d0bcff',
113
+ onAvatar: '#381e72',
114
+ codeSurface: '#1e1e1e',
115
+ codeText: '#d4d4d4',
116
+ toastSurface: '#000000d9',
117
+ toastText: '#f1f3f4',
118
+ toastAction: '#a8c7fa',
119
+ gradientFrom: '#0849ad',
120
+ gradientVia: '#0b57d0',
121
+ gradientTo: '#4285f4',
122
+ washFrom: '#262c38',
123
+ washVia: '#1e242e',
124
+ washTo: '#14161a',
125
+ primaryDeep: '#8fb4f5',
126
+ onGradient: '#ffffff',
127
+ primaryHi: '#6ea8ff',
128
+ dangerHi: '#f08379',
129
+ dangerVia: '#d93025',
130
+ dangerDeep: '#a50e0e',
131
+ warningHi: '#fbbc04',
132
+ warningVia: '#f29900',
133
+ warningDeep: '#e37400',
134
+ warningText: '#f9ab00',
135
+ successHi: '#5fbf77',
136
+ successVia: '#34a853',
137
+ successDeep: '#20713a',
138
+ neutralHi: '#bdc1c6',
139
+ neutralVia: '#80868b',
140
+ neutralDeep: '#5f6368',
141
+ secondaryHi: '#ffffff',
142
+ secondaryVia: '#eef3fd',
143
+ secondaryDeep: '#dbe7fc',
144
+ secondaryBorder: '#c6dafc',
145
+ secondaryLabel: '#0b57d0',
146
+ disabledHi: '#eef0f2',
147
+ disabledVia: '#e3e5e8',
148
+ disabledDeep: '#dadce0',
149
+ },
150
+ };
151
+ /** Elevation presets, 3 named levels (docs/UI_POLISH.md part 1). */
152
+ exports.elevation = {
153
+ level0: {
154
+ shadowColor: '#000000', shadowOpacity: 0, shadowRadius: 0,
155
+ shadowOffset: { width: 0, height: 0 }, elevation: 0,
156
+ },
157
+ level1: {
158
+ shadowColor: '#000000', shadowOpacity: 0.15, shadowRadius: 3,
159
+ shadowOffset: { width: 0, height: 1 }, elevation: 1,
160
+ },
161
+ level2: {
162
+ shadowColor: '#000000', shadowOpacity: 0.25, shadowRadius: 4,
163
+ shadowOffset: { width: 0, height: 2 }, elevation: 3,
164
+ },
165
+ };
166
+ function theme(mode) {
167
+ return { mode, spacing: exports.spacing, radius: exports.radius, typography: exports.typeScale, colors: exports.colours[mode], elevation: exports.elevation };
168
+ }
169
+ /** Both themes as ready-made objects: `themes.light` / `themes.dark`. */
170
+ exports.themes = {
171
+ light: theme('light'),
172
+ dark: theme('dark'),
173
+ };
package/package.json CHANGED
@@ -1,6 +1,30 @@
1
1
  {
2
+ "bin": {
3
+ "rangular-framework": "dist/cli/src/cli.js",
4
+ "rg": "dist/cli/src/cli.js"
5
+ },
6
+ "description": "Command line interface for the Rangular compiler.",
7
+ "license": "Apache-2.0",
8
+ "main": "dist/cli/src/cli.js",
2
9
  "name": "@rangular-framework/cli",
3
- "version": "0.0.0-stage",
4
- "stub": true,
5
- "description": "Temporary package placeholder for staged publishing"
6
- }
10
+ "version": "1.0.1",
11
+ "dependencies": {
12
+ "typescript": "^5.9.0",
13
+ "rxjs": "^7.8.2"
14
+ },
15
+ "files": [
16
+ "dist"
17
+ ],
18
+ "scripts": {
19
+ "build": "tsc -p tsconfig.publish.json",
20
+ "prepack": "npm run build"
21
+ },
22
+ "publishConfig": {
23
+ "access": "public"
24
+ },
25
+ "repository": {
26
+ "type": "git",
27
+ "url": "git+https://github.com/bigyanchap/rangular-framework.git",
28
+ "directory": "packages/cli"
29
+ }
30
+ }
package/README.md DELETED
@@ -1,3 +0,0 @@
1
- # Temporary Holding Version
2
-
3
- This version is a temporary placeholder for this package. An operational version to replace this has been submitted for review and is awaiting a staged release.