@typespec/emitter-framework 0.15.0-dev.3 → 0.15.0-dev.4

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 (253) hide show
  1. package/CHANGELOG.md +1 -16
  2. package/dist/src/python/builtins.d.ts +14 -0
  3. package/dist/src/python/builtins.d.ts.map +1 -0
  4. package/dist/src/python/builtins.js +29 -0
  5. package/dist/src/python/builtins.js.map +1 -0
  6. package/dist/src/python/components/array-expression/array-expression.d.ts +6 -0
  7. package/dist/src/python/components/array-expression/array-expression.d.ts.map +1 -0
  8. package/dist/src/python/components/array-expression/array-expression.js +11 -0
  9. package/dist/src/python/components/array-expression/array-expression.js.map +1 -0
  10. package/dist/src/python/components/array-expression/array-expression.test.d.ts +2 -0
  11. package/dist/src/python/components/array-expression/array-expression.test.d.ts.map +1 -0
  12. package/dist/src/python/components/array-expression/array-expression.test.js +19 -0
  13. package/dist/src/python/components/array-expression/array-expression.test.js.map +1 -0
  14. package/dist/src/python/components/array-expression/index.d.ts +2 -0
  15. package/dist/src/python/components/array-expression/index.d.ts.map +1 -0
  16. package/dist/src/python/components/array-expression/index.js +2 -0
  17. package/dist/src/python/components/array-expression/index.js.map +1 -0
  18. package/dist/src/python/components/atom/atom.d.ts +33 -0
  19. package/dist/src/python/components/atom/atom.d.ts.map +1 -0
  20. package/dist/src/python/components/atom/atom.js +88 -0
  21. package/dist/src/python/components/atom/atom.js.map +1 -0
  22. package/dist/src/python/components/atom/atom.test.d.ts +2 -0
  23. package/dist/src/python/components/atom/atom.test.d.ts.map +1 -0
  24. package/dist/src/python/components/atom/atom.test.js +224 -0
  25. package/dist/src/python/components/atom/atom.test.js.map +1 -0
  26. package/dist/src/python/components/atom/index.d.ts +2 -0
  27. package/dist/src/python/components/atom/index.d.ts.map +1 -0
  28. package/dist/src/python/components/atom/index.js +2 -0
  29. package/dist/src/python/components/atom/index.js.map +1 -0
  30. package/dist/src/python/components/class-declaration/class-bases.d.ts +45 -0
  31. package/dist/src/python/components/class-declaration/class-bases.d.ts.map +1 -0
  32. package/dist/src/python/components/class-declaration/class-bases.js +84 -0
  33. package/dist/src/python/components/class-declaration/class-bases.js.map +1 -0
  34. package/dist/src/python/components/class-declaration/class-body.d.ts +16 -0
  35. package/dist/src/python/components/class-declaration/class-body.d.ts.map +1 -0
  36. package/dist/src/python/components/class-declaration/class-body.js +52 -0
  37. package/dist/src/python/components/class-declaration/class-body.js.map +1 -0
  38. package/dist/src/python/components/class-declaration/class-declaration.d.ts +23 -0
  39. package/dist/src/python/components/class-declaration/class-declaration.d.ts.map +1 -0
  40. package/dist/src/python/components/class-declaration/class-declaration.js +118 -0
  41. package/dist/src/python/components/class-declaration/class-declaration.js.map +1 -0
  42. package/dist/src/python/components/class-declaration/class-declaration.test.d.ts +2 -0
  43. package/dist/src/python/components/class-declaration/class-declaration.test.d.ts.map +1 -0
  44. package/dist/src/python/components/class-declaration/class-declaration.test.js +1527 -0
  45. package/dist/src/python/components/class-declaration/class-declaration.test.js.map +1 -0
  46. package/dist/src/python/components/class-declaration/class-member.d.ts +16 -0
  47. package/dist/src/python/components/class-declaration/class-member.d.ts.map +1 -0
  48. package/dist/src/python/components/class-declaration/class-member.js +71 -0
  49. package/dist/src/python/components/class-declaration/class-member.js.map +1 -0
  50. package/dist/src/python/components/class-declaration/class-member.test.d.ts +2 -0
  51. package/dist/src/python/components/class-declaration/class-member.test.d.ts.map +1 -0
  52. package/dist/src/python/components/class-declaration/class-member.test.js +202 -0
  53. package/dist/src/python/components/class-declaration/class-member.test.js.map +1 -0
  54. package/dist/src/python/components/class-declaration/class-method.d.ts +22 -0
  55. package/dist/src/python/components/class-declaration/class-method.d.ts.map +1 -0
  56. package/dist/src/python/components/class-declaration/class-method.js +76 -0
  57. package/dist/src/python/components/class-declaration/class-method.js.map +1 -0
  58. package/dist/src/python/components/class-declaration/class-method.test.d.ts +2 -0
  59. package/dist/src/python/components/class-declaration/class-method.test.d.ts.map +1 -0
  60. package/dist/src/python/components/class-declaration/class-method.test.js +298 -0
  61. package/dist/src/python/components/class-declaration/class-method.test.js.map +1 -0
  62. package/dist/src/python/components/class-declaration/index.d.ts +7 -0
  63. package/dist/src/python/components/class-declaration/index.d.ts.map +1 -0
  64. package/dist/src/python/components/class-declaration/index.js +7 -0
  65. package/dist/src/python/components/class-declaration/index.js.map +1 -0
  66. package/dist/src/python/components/class-declaration/primitive-initializer.d.ts +22 -0
  67. package/dist/src/python/components/class-declaration/primitive-initializer.d.ts.map +1 -0
  68. package/dist/src/python/components/class-declaration/primitive-initializer.js +67 -0
  69. package/dist/src/python/components/class-declaration/primitive-initializer.js.map +1 -0
  70. package/dist/src/python/components/doc-element/doc-element.d.ts +46 -0
  71. package/dist/src/python/components/doc-element/doc-element.d.ts.map +1 -0
  72. package/dist/src/python/components/doc-element/doc-element.js +59 -0
  73. package/dist/src/python/components/doc-element/doc-element.js.map +1 -0
  74. package/dist/src/python/components/doc-element/index.d.ts +2 -0
  75. package/dist/src/python/components/doc-element/index.d.ts.map +1 -0
  76. package/dist/src/python/components/doc-element/index.js +2 -0
  77. package/dist/src/python/components/doc-element/index.js.map +1 -0
  78. package/dist/src/python/components/enum-declaration/enum-declaration.d.ts +8 -0
  79. package/dist/src/python/components/enum-declaration/enum-declaration.d.ts.map +1 -0
  80. package/dist/src/python/components/enum-declaration/enum-declaration.js +80 -0
  81. package/dist/src/python/components/enum-declaration/enum-declaration.js.map +1 -0
  82. package/dist/src/python/components/enum-declaration/enum-declaration.test.d.ts +2 -0
  83. package/dist/src/python/components/enum-declaration/enum-declaration.test.d.ts.map +1 -0
  84. package/dist/src/python/components/enum-declaration/enum-declaration.test.js +344 -0
  85. package/dist/src/python/components/enum-declaration/enum-declaration.test.js.map +1 -0
  86. package/dist/src/python/components/enum-declaration/enum-member.d.ts +9 -0
  87. package/dist/src/python/components/enum-declaration/enum-member.d.ts.map +1 -0
  88. package/dist/src/python/components/enum-declaration/enum-member.js +22 -0
  89. package/dist/src/python/components/enum-declaration/enum-member.js.map +1 -0
  90. package/dist/src/python/components/enum-declaration/index.d.ts +3 -0
  91. package/dist/src/python/components/enum-declaration/index.d.ts.map +1 -0
  92. package/dist/src/python/components/enum-declaration/index.js +3 -0
  93. package/dist/src/python/components/enum-declaration/index.js.map +1 -0
  94. package/dist/src/python/components/function-declaration/function-declaration.d.ts +24 -0
  95. package/dist/src/python/components/function-declaration/function-declaration.d.ts.map +1 -0
  96. package/dist/src/python/components/function-declaration/function-declaration.js +68 -0
  97. package/dist/src/python/components/function-declaration/function-declaration.js.map +1 -0
  98. package/dist/src/python/components/function-declaration/function-declaration.test.d.ts +2 -0
  99. package/dist/src/python/components/function-declaration/function-declaration.test.d.ts.map +1 -0
  100. package/dist/src/python/components/function-declaration/function-declaration.test.js +682 -0
  101. package/dist/src/python/components/function-declaration/function-declaration.test.js.map +1 -0
  102. package/dist/src/python/components/function-declaration/index.d.ts +2 -0
  103. package/dist/src/python/components/function-declaration/index.d.ts.map +1 -0
  104. package/dist/src/python/components/function-declaration/index.js +2 -0
  105. package/dist/src/python/components/function-declaration/index.js.map +1 -0
  106. package/dist/src/python/components/index.d.ts +12 -0
  107. package/dist/src/python/components/index.d.ts.map +1 -0
  108. package/dist/src/python/components/index.js +12 -0
  109. package/dist/src/python/components/index.js.map +1 -0
  110. package/dist/src/python/components/protocol-declaration/callable-parameters.d.ts +25 -0
  111. package/dist/src/python/components/protocol-declaration/callable-parameters.d.ts.map +1 -0
  112. package/dist/src/python/components/protocol-declaration/callable-parameters.js +33 -0
  113. package/dist/src/python/components/protocol-declaration/callable-parameters.js.map +1 -0
  114. package/dist/src/python/components/protocol-declaration/index.d.ts +3 -0
  115. package/dist/src/python/components/protocol-declaration/index.d.ts.map +1 -0
  116. package/dist/src/python/components/protocol-declaration/index.js +3 -0
  117. package/dist/src/python/components/protocol-declaration/index.js.map +1 -0
  118. package/dist/src/python/components/protocol-declaration/protocol-declaration.d.ts +8 -0
  119. package/dist/src/python/components/protocol-declaration/protocol-declaration.d.ts.map +1 -0
  120. package/dist/src/python/components/protocol-declaration/protocol-declaration.js +86 -0
  121. package/dist/src/python/components/protocol-declaration/protocol-declaration.js.map +1 -0
  122. package/dist/src/python/components/protocol-declaration/protocol-declaration.test.d.ts +2 -0
  123. package/dist/src/python/components/protocol-declaration/protocol-declaration.test.d.ts.map +1 -0
  124. package/dist/src/python/components/protocol-declaration/protocol-declaration.test.js +117 -0
  125. package/dist/src/python/components/protocol-declaration/protocol-declaration.test.js.map +1 -0
  126. package/dist/src/python/components/record-expression/index.d.ts +2 -0
  127. package/dist/src/python/components/record-expression/index.d.ts.map +1 -0
  128. package/dist/src/python/components/record-expression/index.js +2 -0
  129. package/dist/src/python/components/record-expression/index.js.map +1 -0
  130. package/dist/src/python/components/record-expression/record-expression.d.ts +6 -0
  131. package/dist/src/python/components/record-expression/record-expression.d.ts.map +1 -0
  132. package/dist/src/python/components/record-expression/record-expression.js +13 -0
  133. package/dist/src/python/components/record-expression/record-expression.js.map +1 -0
  134. package/dist/src/python/components/record-expression/record-expression.test.d.ts +2 -0
  135. package/dist/src/python/components/record-expression/record-expression.test.d.ts.map +1 -0
  136. package/dist/src/python/components/record-expression/record-expression.test.js +19 -0
  137. package/dist/src/python/components/record-expression/record-expression.test.js.map +1 -0
  138. package/dist/src/python/components/type-alias-declaration/index.d.ts +2 -0
  139. package/dist/src/python/components/type-alias-declaration/index.d.ts.map +1 -0
  140. package/dist/src/python/components/type-alias-declaration/index.js +2 -0
  141. package/dist/src/python/components/type-alias-declaration/index.js.map +1 -0
  142. package/dist/src/python/components/type-alias-declaration/type-alias-declaration.d.ts +16 -0
  143. package/dist/src/python/components/type-alias-declaration/type-alias-declaration.d.ts.map +1 -0
  144. package/dist/src/python/components/type-alias-declaration/type-alias-declaration.js +75 -0
  145. package/dist/src/python/components/type-alias-declaration/type-alias-declaration.js.map +1 -0
  146. package/dist/src/python/components/type-alias-declaration/type-alias-declaration.test.d.ts +2 -0
  147. package/dist/src/python/components/type-alias-declaration/type-alias-declaration.test.d.ts.map +1 -0
  148. package/dist/src/python/components/type-alias-declaration/type-alias-declaration.test.js +140 -0
  149. package/dist/src/python/components/type-alias-declaration/type-alias-declaration.test.js.map +1 -0
  150. package/dist/src/python/components/type-declaration/index.d.ts +2 -0
  151. package/dist/src/python/components/type-declaration/index.d.ts.map +1 -0
  152. package/dist/src/python/components/type-declaration/index.js +2 -0
  153. package/dist/src/python/components/type-declaration/index.js.map +1 -0
  154. package/dist/src/python/components/type-declaration/type-declaration.d.ts +11 -0
  155. package/dist/src/python/components/type-declaration/type-declaration.d.ts.map +1 -0
  156. package/dist/src/python/components/type-declaration/type-declaration.js +31 -0
  157. package/dist/src/python/components/type-declaration/type-declaration.js.map +1 -0
  158. package/dist/src/python/components/type-declaration/type-declaration.test.d.ts +2 -0
  159. package/dist/src/python/components/type-declaration/type-declaration.test.d.ts.map +1 -0
  160. package/dist/src/python/components/type-declaration/type-declaration.test.js +69 -0
  161. package/dist/src/python/components/type-declaration/type-declaration.test.js.map +1 -0
  162. package/dist/src/python/components/type-expression/index.d.ts +2 -0
  163. package/dist/src/python/components/type-expression/index.d.ts.map +1 -0
  164. package/dist/src/python/components/type-expression/index.js +2 -0
  165. package/dist/src/python/components/type-expression/index.js.map +1 -0
  166. package/dist/src/python/components/type-expression/type-expression.d.ts +12 -0
  167. package/dist/src/python/components/type-expression/type-expression.d.ts.map +1 -0
  168. package/dist/src/python/components/type-expression/type-expression.js +348 -0
  169. package/dist/src/python/components/type-expression/type-expression.js.map +1 -0
  170. package/dist/src/python/components/type-expression/type-expression.test.d.ts +2 -0
  171. package/dist/src/python/components/type-expression/type-expression.test.d.ts.map +1 -0
  172. package/dist/src/python/components/type-expression/type-expression.test.js +503 -0
  173. package/dist/src/python/components/type-expression/type-expression.test.js.map +1 -0
  174. package/dist/src/python/index.d.ts +4 -0
  175. package/dist/src/python/index.d.ts.map +1 -0
  176. package/dist/src/python/index.js +4 -0
  177. package/dist/src/python/index.js.map +1 -0
  178. package/dist/src/python/lib.d.ts +68 -0
  179. package/dist/src/python/lib.d.ts.map +1 -0
  180. package/dist/src/python/lib.js +38 -0
  181. package/dist/src/python/lib.js.map +1 -0
  182. package/dist/src/python/test-utils.d.ts +8 -0
  183. package/dist/src/python/test-utils.d.ts.map +1 -0
  184. package/dist/src/python/test-utils.js +25 -0
  185. package/dist/src/python/test-utils.js.map +1 -0
  186. package/dist/src/python/utils/index.d.ts +4 -0
  187. package/dist/src/python/utils/index.d.ts.map +1 -0
  188. package/dist/src/python/utils/index.js +4 -0
  189. package/dist/src/python/utils/index.js.map +1 -0
  190. package/dist/src/python/utils/operation.d.ts +27 -0
  191. package/dist/src/python/utils/operation.d.ts.map +1 -0
  192. package/dist/src/python/utils/operation.js +139 -0
  193. package/dist/src/python/utils/operation.js.map +1 -0
  194. package/dist/src/python/utils/refkey.d.ts +23 -0
  195. package/dist/src/python/utils/refkey.d.ts.map +1 -0
  196. package/dist/src/python/utils/refkey.js +36 -0
  197. package/dist/src/python/utils/refkey.js.map +1 -0
  198. package/dist/src/python/utils/type.d.ts +19 -0
  199. package/dist/src/python/utils/type.d.ts.map +1 -0
  200. package/dist/src/python/utils/type.js +24 -0
  201. package/dist/src/python/utils/type.js.map +1 -0
  202. package/package.json +9 -1
  203. package/package.json.bak +10 -1
  204. package/src/python/builtins.ts +43 -0
  205. package/src/python/components/array-expression/array-expression.test.tsx +14 -0
  206. package/src/python/components/array-expression/array-expression.tsx +11 -0
  207. package/src/python/components/array-expression/index.ts +1 -0
  208. package/src/python/components/atom/atom.test.tsx +244 -0
  209. package/src/python/components/atom/atom.tsx +95 -0
  210. package/src/python/components/atom/index.ts +1 -0
  211. package/src/python/components/class-declaration/class-bases.tsx +92 -0
  212. package/src/python/components/class-declaration/class-body.tsx +56 -0
  213. package/src/python/components/class-declaration/class-declaration.test.tsx +1414 -0
  214. package/src/python/components/class-declaration/class-declaration.tsx +116 -0
  215. package/src/python/components/class-declaration/class-member.test.tsx +194 -0
  216. package/src/python/components/class-declaration/class-member.tsx +67 -0
  217. package/src/python/components/class-declaration/class-method.test.tsx +250 -0
  218. package/src/python/components/class-declaration/class-method.tsx +97 -0
  219. package/src/python/components/class-declaration/index.ts +6 -0
  220. package/src/python/components/class-declaration/primitive-initializer.tsx +62 -0
  221. package/src/python/components/doc-element/doc-element.tsx +83 -0
  222. package/src/python/components/doc-element/index.ts +1 -0
  223. package/src/python/components/enum-declaration/enum-declaration.test.tsx +319 -0
  224. package/src/python/components/enum-declaration/enum-declaration.tsx +77 -0
  225. package/src/python/components/enum-declaration/enum-member.tsx +21 -0
  226. package/src/python/components/enum-declaration/index.ts +2 -0
  227. package/src/python/components/function-declaration/function-declaration.test.tsx +582 -0
  228. package/src/python/components/function-declaration/function-declaration.tsx +90 -0
  229. package/src/python/components/function-declaration/index.ts +1 -0
  230. package/src/python/components/index.ts +11 -0
  231. package/src/python/components/protocol-declaration/callable-parameters.tsx +44 -0
  232. package/src/python/components/protocol-declaration/index.ts +2 -0
  233. package/src/python/components/protocol-declaration/protocol-declaration.test.tsx +106 -0
  234. package/src/python/components/protocol-declaration/protocol-declaration.tsx +73 -0
  235. package/src/python/components/record-expression/index.ts +1 -0
  236. package/src/python/components/record-expression/record-expression.test.tsx +14 -0
  237. package/src/python/components/record-expression/record-expression.tsx +13 -0
  238. package/src/python/components/type-alias-declaration/index.ts +1 -0
  239. package/src/python/components/type-alias-declaration/type-alias-declaration.test.tsx +117 -0
  240. package/src/python/components/type-alias-declaration/type-alias-declaration.tsx +67 -0
  241. package/src/python/components/type-declaration/index.ts +1 -0
  242. package/src/python/components/type-declaration/type-declaration.test.tsx +58 -0
  243. package/src/python/components/type-declaration/type-declaration.tsx +26 -0
  244. package/src/python/components/type-expression/index.ts +1 -0
  245. package/src/python/components/type-expression/type-expression.test.tsx +463 -0
  246. package/src/python/components/type-expression/type-expression.tsx +333 -0
  247. package/src/python/index.ts +3 -0
  248. package/src/python/lib.ts +40 -0
  249. package/src/python/test-utils.tsx +31 -0
  250. package/src/python/utils/index.ts +3 -0
  251. package/src/python/utils/operation.ts +161 -0
  252. package/src/python/utils/refkey.ts +36 -0
  253. package/src/python/utils/type.ts +31 -0
package/CHANGELOG.md CHANGED
@@ -14,7 +14,6 @@ No changes, version bump only.
14
14
 
15
15
  - [#8823](https://github.com/microsoft/typespec/pull/8823) Upgrade dependencies
16
16
 
17
-
18
17
  ## 0.12.0
19
18
 
20
19
  ### Features
@@ -29,7 +28,6 @@ No changes, version bump only.
29
28
 
30
29
  - [#8474](https://github.com/microsoft/typespec/pull/8474) Remove development exports from published package
31
30
 
32
-
33
31
  ## 0.11.0
34
32
 
35
33
  ### Features
@@ -53,7 +51,6 @@ No changes, version bump only.
53
51
  - [#8302](https://github.com/microsoft/typespec/pull/8302) [c#] Avoid generating double '?' after property name when the property is nullable union and it's prop.optional is true in the meantime
54
52
  - [#8362](https://github.com/microsoft/typespec/pull/8362) Upgrade alloy to 0.20
55
53
 
56
-
57
54
  ## 0.10.0
58
55
 
59
56
  ### Bump dependencies
@@ -61,7 +58,6 @@ No changes, version bump only.
61
58
  - [#8050](https://github.com/microsoft/typespec/pull/8050) Upgrade alloy 0.19
62
59
  - [#7978](https://github.com/microsoft/typespec/pull/7978) Upgrade dependencies
63
60
 
64
-
65
61
  ## 0.9.0
66
62
 
67
63
  ### Features
@@ -79,7 +75,6 @@ No changes, version bump only.
79
75
 
80
76
  - [#7650](https://github.com/microsoft/typespec/pull/7650) Adds subpath export for csharp emitter-framework components
81
77
 
82
-
83
78
  ## 0.8.0
84
79
 
85
80
  ### Features
@@ -94,7 +89,6 @@ No changes, version bump only.
94
89
 
95
90
  - [#7369](https://github.com/microsoft/typespec/pull/7369) Render discriminated unions correctly
96
91
 
97
-
98
92
  ## 0.7.1
99
93
 
100
94
  ### Bump dependencies
@@ -105,21 +99,19 @@ No changes, version bump only.
105
99
 
106
100
  - [#7321](https://github.com/microsoft/typespec/pull/7321) Use wasm version of tree sitter for snippet extractor
107
101
 
108
-
109
102
  ## 0.7.0
110
103
 
111
104
  ### Bump dependencies
112
105
 
113
106
  - [#7186](https://github.com/microsoft/typespec/pull/7186) Upgrade to alloy 15
114
107
 
115
-
116
108
  ## 0.6.0
117
109
 
118
110
  ### Features
119
111
 
120
112
  - [#7017](https://github.com/microsoft/typespec/pull/7017) [TypeScript] Add various function-related components - FunctionType, FunctionExpression, ArrowFunction, and InterfaceMethod.
121
113
  - [#6972](https://github.com/microsoft/typespec/pull/6972) Add support for rendering a Value Expression
122
- - [#7018](https://github.com/microsoft/typespec/pull/7018) Adds the `TspContextProvider` and `useTsp()` hook for providing and accessing TypeSpec context and the Typekit APIs (e.g. `# Changelog - @typespec/emitter-framework). Adds a new `Output` component that accepts a TypeSpec `Program` and automatically wraps children components with the `TspContextProvider`.
114
+ - [#7018](https://github.com/microsoft/typespec/pull/7018) Adds the `TspContextProvider` and `useTsp()` hook for providing and accessing TypeSpec context and the Typekit APIs (e.g. `# Changelog - @typespec/emitter-framework). Adds a new `Output`component that accepts a TypeSpec`Program`and automatically wraps children components with the`TspContextProvider`.
123
115
 
124
116
  ### Bump dependencies
125
117
 
@@ -129,21 +121,18 @@ No changes, version bump only.
129
121
 
130
122
  - [#6951](https://github.com/microsoft/typespec/pull/6951) InterfaceMember should use Alloy
131
123
 
132
-
133
124
  ## 0.5.0
134
125
 
135
126
  ### Features
136
127
 
137
128
  - [#6875](https://github.com/microsoft/typespec/pull/6875) Upgrade to alloy 0.10.0
138
129
 
139
-
140
130
  ## 0.4.0
141
131
 
142
132
  ### Bump dependencies
143
133
 
144
134
  - [#6595](https://github.com/microsoft/typespec/pull/6595) Upgrade dependencies
145
135
 
146
-
147
136
  ## 0.3.0
148
137
 
149
138
  ### Bump dependencies
@@ -155,12 +144,8 @@ No changes, version bump only.
155
144
  - [#6178](https://github.com/microsoft/typespec/pull/6178) Improvements on the TestHarness
156
145
  - [#6460](https://github.com/microsoft/typespec/pull/6460) Update dependency structure for EmitterFramework, HttpClient and JS Emitter
157
146
 
158
-
159
-
160
-
161
147
  ## 0.2.0
162
148
 
163
149
  ### Features
164
150
 
165
151
  - [#5996](https://github.com/microsoft/typespec/pull/5996) Adding Emitter Framework and Http Client packages
166
-
@@ -0,0 +1,14 @@
1
+ import type { SymbolCreator } from "@alloy-js/core";
2
+ export declare const abcModule: import("@alloy-js/python").ModuleRefkeys<{
3
+ readonly ".": ["ABC"];
4
+ }> & SymbolCreator;
5
+ export declare const datetimeModule: import("@alloy-js/python").ModuleRefkeys<{
6
+ readonly ".": ["datetime", "date", "time", "timedelta", "timezone"];
7
+ }> & SymbolCreator;
8
+ export declare const decimalModule: import("@alloy-js/python").ModuleRefkeys<{
9
+ readonly ".": ["Decimal"];
10
+ }> & SymbolCreator;
11
+ export declare const typingModule: import("@alloy-js/python").ModuleRefkeys<{
12
+ readonly ".": ["Any", "Callable", "Generic", "Literal", "Never", "Optional", "Protocol", "TypeAlias", "TypeVar"];
13
+ }> & SymbolCreator;
14
+ //# sourceMappingURL=builtins.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"builtins.d.ts","sourceRoot":"","sources":["../../../src/python/builtins.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,gBAAgB,CAAC;AAMpD,eAAO,MAAM,SAAS;;kBAKpB,CAAC;AAEH,eAAO,MAAM,cAAc;;kBAKzB,CAAC;AAEH,eAAO,MAAM,aAAa;;kBAKxB,CAAC;AAEH,eAAO,MAAM,YAAY;;kBAevB,CAAC"}
@@ -0,0 +1,29 @@
1
+ import { createModule } from "@alloy-js/python";
2
+
3
+ // eslint-disable-next-line @typescript-eslint/no-unused-vars
4
+
5
+ export const abcModule = createModule({
6
+ name: "abc",
7
+ descriptor: {
8
+ ".": ["ABC"]
9
+ }
10
+ });
11
+ export const datetimeModule = createModule({
12
+ name: "datetime",
13
+ descriptor: {
14
+ ".": ["datetime", "date", "time", "timedelta", "timezone"]
15
+ }
16
+ });
17
+ export const decimalModule = createModule({
18
+ name: "decimal",
19
+ descriptor: {
20
+ ".": ["Decimal"]
21
+ }
22
+ });
23
+ export const typingModule = createModule({
24
+ name: "typing",
25
+ descriptor: {
26
+ ".": ["Any", "Callable", "Generic", "Literal", "Never", "Optional", "Protocol", "TypeAlias", "TypeVar"]
27
+ }
28
+ });
29
+ //# sourceMappingURL=builtins.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"names":["createModule","abcModule","name","descriptor","datetimeModule","decimalModule","typingModule"],"sources":["../../../src/python/builtins.ts"],"sourcesContent":[null],"mappings":"AACA,SAASA,YAAY,QAAQ,kBAAkB;;AAE/C;;AAGA,OAAO,MAAMC,SAAS,GAAGD,YAAY,CAAC;EACpCE,IAAI,EAAE,KAAK;EACXC,UAAU,EAAE;IACV,GAAG,EAAE,CAAC,KAAK;EACb;AACF,CAAC,CAAC;AAEF,OAAO,MAAMC,cAAc,GAAGJ,YAAY,CAAC;EACzCE,IAAI,EAAE,UAAU;EAChBC,UAAU,EAAE;IACV,GAAG,EAAE,CAAC,UAAU,EAAE,MAAM,EAAE,MAAM,EAAE,WAAW,EAAE,UAAU;EAC3D;AACF,CAAC,CAAC;AAEF,OAAO,MAAME,aAAa,GAAGL,YAAY,CAAC;EACxCE,IAAI,EAAE,SAAS;EACfC,UAAU,EAAE;IACV,GAAG,EAAE,CAAC,SAAS;EACjB;AACF,CAAC,CAAC;AAEF,OAAO,MAAMG,YAAY,GAAGN,YAAY,CAAC;EACvCE,IAAI,EAAE,QAAQ;EACdC,UAAU,EAAE;IACV,GAAG,EAAE,CACH,KAAK,EACL,UAAU,EACV,SAAS,EACT,SAAS,EACT,OAAO,EACP,UAAU,EACV,UAAU,EACV,WAAW,EACX,SAAS;EAEb;AACF,CAAC,CAAC","ignoreList":[]}
@@ -0,0 +1,6 @@
1
+ import type { Type } from "@typespec/compiler";
2
+ export interface ArrayExpressionProps {
3
+ elementType: Type;
4
+ }
5
+ export declare function ArrayExpression({ elementType }: ArrayExpressionProps): import("@alloy-js/core").Children;
6
+ //# sourceMappingURL=array-expression.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"array-expression.d.ts","sourceRoot":"","sources":["../../../../../src/python/components/array-expression/array-expression.tsx"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,IAAI,EAAE,MAAM,oBAAoB,CAAC;AAG/C,MAAM,WAAW,oBAAoB;IACnC,WAAW,EAAE,IAAI,CAAC;CACnB;AAED,wBAAgB,eAAe,CAAC,EAAE,WAAW,EAAE,EAAE,oBAAoB,qCAEpE"}
@@ -0,0 +1,11 @@
1
+ import { createComponent as _$createComponent } from "@alloy-js/core/jsx-runtime";
2
+ import { code } from "@alloy-js/core";
3
+ import { TypeExpression } from "../type-expression/type-expression.js";
4
+ export function ArrayExpression({
5
+ elementType
6
+ }) {
7
+ return code`list[${_$createComponent(TypeExpression, {
8
+ type: elementType
9
+ })}]`;
10
+ }
11
+ //# sourceMappingURL=array-expression.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"names":["code","TypeExpression","ArrayExpression","elementType","_$createComponent","type"],"sources":["../../../../../src/python/components/array-expression/array-expression.tsx"],"sourcesContent":[null],"mappings":";AAAA,SAASA,IAAI,QAAQ,gBAAgB;AAErC,SAASC,cAAc,QAAQ,uCAAuC;AAMtE,OAAO,SAASC,eAAeA,CAAC;EAAEC;AAAkC,CAAC,EAAE;EACrE,OAAOH,IAAI,QAAAI,iBAAA,CAAUH,cAAc;IAACI,IAAI,EAAEF;EAAW,KAAQ;AAC/D","ignoreList":[]}
@@ -0,0 +1,2 @@
1
+ export {};
2
+ //# sourceMappingURL=array-expression.test.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"array-expression.test.d.ts","sourceRoot":"","sources":["../../../../../src/python/components/array-expression/array-expression.test.tsx"],"names":[],"mappings":""}
@@ -0,0 +1,19 @@
1
+ import { createComponent as _$createComponent } from "@alloy-js/core/jsx-runtime";
2
+ import { Tester } from "#test/test-host.js";
3
+ import { d } from "@alloy-js/core/testing";
4
+ import { t } from "@typespec/compiler/testing";
5
+ import { expect, it } from "vitest";
6
+ import { getOutput } from "../../test-utils.js";
7
+ import { TypeExpression } from "../type-expression/type-expression.js";
8
+ it("maps array expression to Python list", async () => {
9
+ const {
10
+ program,
11
+ TestArray
12
+ } = await Tester.compile(t.code`
13
+ alias ${t.type("TestArray")} = string[];
14
+ `);
15
+ expect(getOutput(program, [_$createComponent(TypeExpression, {
16
+ type: TestArray
17
+ })])).toRenderTo(d`list[str]`);
18
+ });
19
+ //# sourceMappingURL=array-expression.test.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"names":["Tester","d","t","expect","it","getOutput","TypeExpression","program","TestArray","compile","code","type","_$createComponent","toRenderTo"],"sources":["../../../../../src/python/components/array-expression/array-expression.test.tsx"],"sourcesContent":[null],"mappings":";AAAA,SAASA,MAAM,QAAQ,oBAAoB;AAC3C,SAASC,CAAC,QAAQ,wBAAwB;AAC1C,SAASC,CAAC,QAAQ,4BAA4B;AAC9C,SAASC,MAAM,EAAEC,EAAE,QAAQ,QAAQ;AACnC,SAASC,SAAS,QAAQ,qBAAqB;AAC/C,SAASC,cAAc,QAAQ,uCAAuC;AAEtEF,EAAE,CAAC,sCAAsC,EAAE,YAAY;EACrD,MAAM;IAAEG,OAAO;IAAEC;EAAU,CAAC,GAAG,MAAMR,MAAM,CAACS,OAAO,CAACP,CAAC,CAACQ,IAAI;AAC5D,YAAYR,CAAC,CAACS,IAAI,CAAC,WAAW,CAAC;AAC/B,GAAG,CAAC;EAEFR,MAAM,CAACE,SAAS,CAACE,OAAO,EAAE,CAAAK,iBAAA,CAAEN,cAAc;IAACK,IAAI,EAAEH;EAAS,GAAK,CAAC,CAAC,CAACK,UAAU,CAACZ,CAAC,WAAW,CAAC;AAC5F,CAAC,CAAC","ignoreList":[]}
@@ -0,0 +1,2 @@
1
+ export * from "./array-expression.js";
2
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/python/components/array-expression/index.ts"],"names":[],"mappings":"AAAA,cAAc,uBAAuB,CAAC"}
@@ -0,0 +1,2 @@
1
+ export * from "./array-expression.js";
2
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"names":[],"sources":["../../../../../src/python/components/array-expression/index.ts"],"sourcesContent":[null],"mappings":"AAAA,cAAc,uBAAuB","ignoreList":[]}
@@ -0,0 +1,33 @@
1
+ import { type Children } from "@alloy-js/core";
2
+ import { type Value } from "@typespec/compiler";
3
+ /**
4
+ * Base properties for the {@link Atom} component.
5
+ */
6
+ interface BaseAtomProps {
7
+ /**
8
+ * The TypeSpec value to be converted to a Python expression.
9
+ */
10
+ value: Value;
11
+ }
12
+ /**
13
+ * Properties for the {@link Atom} component when dealing with numeric values.
14
+ */
15
+ interface NumericAtomProps extends BaseAtomProps {
16
+ /**
17
+ * Hint that this numeric value should be emitted as a float (e.g., 42 -> 42.0).
18
+ * Only affects NumericValue.
19
+ */
20
+ float?: boolean;
21
+ }
22
+ /**
23
+ * All possible properties for the {@link Atom} component.
24
+ */
25
+ type AtomProps = BaseAtomProps | NumericAtomProps;
26
+ /**
27
+ * Generates a Python atom from a TypeSpec value.
28
+ * @param props properties for the atom
29
+ * @returns {@link Children} representing the Python value expression
30
+ */
31
+ export declare function Atom(props: Readonly<AtomProps>): Children;
32
+ export {};
33
+ //# sourceMappingURL=atom.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"atom.d.ts","sourceRoot":"","sources":["../../../../../src/python/components/atom/atom.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,QAAQ,EAAE,MAAM,gBAAgB,CAAC;AAE/C,OAAO,EAAkB,KAAK,KAAK,EAAE,MAAM,oBAAoB,CAAC;AAGhE;;GAEG;AACH,UAAU,aAAa;IACrB;;OAEG;IACH,KAAK,EAAE,KAAK,CAAC;CACd;AAED;;GAEG;AACH,UAAU,gBAAiB,SAAQ,aAAa;IAC9C;;;OAGG;IACH,KAAK,CAAC,EAAE,OAAO,CAAC;CACjB;AAED;;GAEG;AACH,KAAK,SAAS,GAAG,aAAa,GAAG,gBAAgB,CAAC;AAElD;;;;GAIG;AACH,wBAAgB,IAAI,CAAC,KAAK,EAAE,QAAQ,CAAC,SAAS,CAAC,GAAG,QAAQ,CAqCzD"}
@@ -0,0 +1,88 @@
1
+ import { createComponent as _$createComponent, memo as _$memo } from "@alloy-js/core/jsx-runtime";
2
+ import * as py from "@alloy-js/python";
3
+ import { compilerAssert } from "@typespec/compiler";
4
+ import { datetimeModule } from "../../builtins.js";
5
+
6
+ /**
7
+ * Base properties for the {@link Atom} component.
8
+ */
9
+
10
+ /**
11
+ * Properties for the {@link Atom} component when dealing with numeric values.
12
+ */
13
+
14
+ /**
15
+ * All possible properties for the {@link Atom} component.
16
+ */
17
+
18
+ /**
19
+ * Generates a Python atom from a TypeSpec value.
20
+ * @param props properties for the atom
21
+ * @returns {@link Children} representing the Python value expression
22
+ */
23
+ export function Atom(props) {
24
+ switch (props.value.valueKind) {
25
+ case "StringValue":
26
+ case "BooleanValue":
27
+ case "NullValue":
28
+ return _$createComponent(py.Atom, {
29
+ get jsValue() {
30
+ return props.value.value;
31
+ }
32
+ });
33
+ case "NumericValue":
34
+ {
35
+ const num = props.value.value.asNumber();
36
+ const isNonInteger = num != null && !Number.isInteger(num);
37
+ const numericProps = props;
38
+ const asFloat = isNonInteger || numericProps.float;
39
+ return _$createComponent(py.Atom, {
40
+ jsValue: num,
41
+ asFloat: asFloat
42
+ });
43
+ }
44
+ case "ArrayValue":
45
+ return _$createComponent(py.Atom, {
46
+ get jsValue() {
47
+ return props.value.values.map(v => _$createComponent(Atom, {
48
+ value: v
49
+ }));
50
+ }
51
+ });
52
+ case "ScalarValue":
53
+ compilerAssert(props.value.value.name === "fromISO", `Unsupported scalar constructor ${props.value.value.name}`, props.value);
54
+ return handleISOStringValue(props.value);
55
+ case "ObjectValue":
56
+ const jsProperties = {};
57
+ for (const [key, value] of props.value.properties) {
58
+ jsProperties[key] = Atom({
59
+ value: value.value
60
+ });
61
+ }
62
+ return _$createComponent(py.Atom, {
63
+ jsValue: jsProperties
64
+ });
65
+ case "EnumValue":
66
+ return _$createComponent(py.Atom, {
67
+ get jsValue() {
68
+ return props.value.value.value ?? props.value.value.name;
69
+ }
70
+ });
71
+ }
72
+ }
73
+
74
+ /**
75
+ * Handles the conversion of ISO date strings to Python datetime objects.
76
+ * @param value the TypeSpec value containing the ISO string
77
+ * @returns {@link Children} representing the Python datetime expression
78
+ */
79
+ function handleISOStringValue(value) {
80
+ const arg0 = value.value.args[0];
81
+ if (arg0.valueKind !== "StringValue") {
82
+ throw new Error("Expected arg0 to be a StringValue");
83
+ }
84
+ const isoString = arg0.value;
85
+ const date = new Date(isoString);
86
+ return [_$memo(() => datetimeModule["."]["datetime"]), "(", _$memo(() => date.getUTCFullYear()), ", ", _$memo(() => date.getUTCMonth() + 1), ",", " ", _$memo(() => date.getUTCDate()), ", ", _$memo(() => date.getUTCHours()), ", ", _$memo(() => date.getUTCMinutes()), ", ", _$memo(() => date.getUTCSeconds()), ", tzinfo=", _$memo(() => datetimeModule["."]["timezone"]), ".utc)"];
87
+ }
88
+ //# sourceMappingURL=atom.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"names":["py","compilerAssert","datetimeModule","Atom","props","value","valueKind","_$createComponent","jsValue","num","asNumber","isNonInteger","Number","isInteger","numericProps","asFloat","float","values","map","v","name","handleISOStringValue","jsProperties","key","properties","arg0","args","Error","isoString","date","Date","_$memo","getUTCFullYear","getUTCMonth","getUTCDate","getUTCHours","getUTCMinutes","getUTCSeconds"],"sources":["../../../../../src/python/components/atom/atom.tsx"],"sourcesContent":[null],"mappings":";AACA,OAAO,KAAKA,EAAE,MAAM,kBAAkB;AACtC,SAASC,cAAc,QAAoB,oBAAoB;AAC/D,SAASC,cAAc,QAAQ,mBAAmB;;AAElD;AACA;AACA;;AAQA;AACA;AACA;;AASA;AACA;AACA;;AAGA;AACA;AACA;AACA;A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F7B,cAAc,CAAC,GAAG,CAAC,CAAC,UAAU,CAAC;AAG7C","ignoreList":[]}
@@ -0,0 +1,2 @@
1
+ export {};
2
+ //# sourceMappingURL=atom.test.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"atom.test.d.ts","sourceRoot":"","sources":["../../../../../src/python/components/atom/atom.test.tsx"],"names":[],"mappings":""}
@@ -0,0 +1,224 @@
1
+ import { createComponent as _$createComponent } from "@alloy-js/core/jsx-runtime";
2
+ import { getOutput } from "#python/test-utils.js";
3
+ import { Tester } from "#test/test-host.js";
4
+ import { t } from "@typespec/compiler/testing";
5
+ import { $ } from "@typespec/compiler/typekit";
6
+ import { assert, beforeAll, describe, expect, it } from "vitest";
7
+ import { Atom } from "../../index.js";
8
+ let program;
9
+ beforeAll(async () => {
10
+ const result = await Tester.compile("");
11
+ program = result.program;
12
+ });
13
+ describe("NullValue", () => {
14
+ it("null value", async () => {
15
+ const value = {
16
+ entityKind: "Value",
17
+ valueKind: "NullValue",
18
+ value: null
19
+ };
20
+ await testValueExpression(value, `None`);
21
+ });
22
+ });
23
+ describe("StringValue", () => {
24
+ it("normal string", async () => {
25
+ const value = $(program).value.createString("test");
26
+ await testValueExpression(value, `"test"`);
27
+ });
28
+ it("empty string", async () => {
29
+ const value = $(program).value.createString("");
30
+ await testValueExpression(value, `""`);
31
+ });
32
+ });
33
+ describe("BooleanValue", () => {
34
+ it("True", async () => {
35
+ const value = $(program).value.createBoolean(true);
36
+ await testValueExpression(value, `True`);
37
+ });
38
+ it("False", async () => {
39
+ const value = $(program).value.createBoolean(false);
40
+ await testValueExpression(value, `False`);
41
+ });
42
+ });
43
+ describe("NumericValue", () => {
44
+ it("integers", async () => {
45
+ const value = $(program).value.createNumeric(42);
46
+ await testValueExpression(value, `42`);
47
+ });
48
+ it("decimals", async () => {
49
+ const fractional = $(program).value.createNumeric(42.5);
50
+ await testValueExpression(fractional, `42.5`);
51
+ });
52
+ it("decimals with .0", async () => {
53
+ // Generic Atom (no hint) normalizes 42.0 to 42 because it uses asNumber()
54
+ const value = $(program).value.createNumeric(42.0);
55
+ await testValueExpression(value, `42`);
56
+ });
57
+ it("decimals with .0 when float", async () => {
58
+ const value = $(program).value.createNumeric(42.0);
59
+ expect(getOutput(program, [_$createComponent(Atom, {
60
+ value: value,
61
+ float: true
62
+ })])).toRenderTo(`42.0`);
63
+ });
64
+ it("negative integers", async () => {
65
+ const value = $(program).value.createNumeric(-42);
66
+ await testValueExpression(value, `-42`);
67
+ });
68
+ it("negative decimals", async () => {
69
+ const value = $(program).value.createNumeric(-42.5);
70
+ await testValueExpression(value, `-42.5`);
71
+ });
72
+ it("zero", async () => {
73
+ const value = $(program).value.createNumeric(0);
74
+ await testValueExpression(value, `0`);
75
+ });
76
+ it("zero with float", async () => {
77
+ const value = $(program).value.createNumeric(0);
78
+ expect(getOutput(program, [_$createComponent(Atom, {
79
+ value: value,
80
+ float: true
81
+ })])).toRenderTo(`0.0`);
82
+ });
83
+ it("exponent that resolves to integer", async () => {
84
+ const value = $(program).value.createNumeric(1e3);
85
+ await testValueExpression(value, `1000`);
86
+ });
87
+ it("exponent that resolves to integer with float", async () => {
88
+ const value = $(program).value.createNumeric(1e3);
89
+ expect(getOutput(program, [_$createComponent(Atom, {
90
+ value: value,
91
+ float: true
92
+ })])).toRenderTo(`1000.0`);
93
+ });
94
+ it("small decimal via exponent", async () => {
95
+ const value = $(program).value.createNumeric(1e-3);
96
+ await testValueExpression(value, `0.001`);
97
+ });
98
+ });
99
+ describe("ArrayValue", () => {
100
+ it("empty", async () => {
101
+ // Can be replaced with TypeKit once #6976 is implemented
102
+ const value = {
103
+ entityKind: "Value",
104
+ valueKind: "ArrayValue",
105
+ values: []
106
+ };
107
+ await testValueExpression(value, `[]`);
108
+ });
109
+ it("with mixed values", async () => {
110
+ // Can be replaced with TypeKit once #6976 is implemented
111
+ const value = {
112
+ entityKind: "Value",
113
+ valueKind: "ArrayValue",
114
+ values: [$(program).value.createString("some_text"), $(program).value.createNumeric(42), $(program).value.createBoolean(true), {
115
+ entityKind: "Value",
116
+ valueKind: "ArrayValue",
117
+ values: [$(program).value.createNumeric(1), $(program).value.createNumeric(2), $(program).value.createNumeric(3)]
118
+ }]
119
+ };
120
+ await testValueExpression(value, `["some_text", 42, True, [1, 2, 3]]`);
121
+ });
122
+ });
123
+ describe("ScalarValue", () => {
124
+ it("utcDateTime.fromISO correctly supplied", async () => {
125
+ const {
126
+ minDate
127
+ } = await Tester.compile(t.code`
128
+ model ${t.model("DateRange")} {
129
+ @encode("rfc7231")
130
+ ${t.modelProperty("minDate")}: ${t.type("utcDateTime")} = utcDateTime.fromISO("2024-02-15T18:36:03Z");
131
+ }
132
+ `);
133
+ await testValueExpression(minDate.defaultValue, `from datetime import datetime
134
+ from datetime import timezone
135
+
136
+
137
+ datetime(2024, 2, 15, 18, 36, 3, tzinfo=timezone.utc)`);
138
+ });
139
+ it("Unsupported scalar constructor", async () => {
140
+ const {
141
+ IpAddress
142
+ } = await Tester.compile(t.code`
143
+ scalar ${t.scalar("ipv4")} extends ${t.scalar("string")} {
144
+ init fromInt(value: uint32);
145
+ }
146
+
147
+ @example (#{ip: ipv4.fromInt(2130706433)})
148
+ model ${t.model("IpAddress")} {
149
+ ${t.modelProperty("ip")}: ${t.type("ipv4")};
150
+ }
151
+ `);
152
+ const value = getExampleValue(IpAddress);
153
+ await expect(testValueExpression(value, ``)).rejects.toThrow(/Unsupported scalar constructor fromInt/);
154
+ });
155
+ });
156
+ describe("ObjectValue", () => {
157
+ it("empty object", async () => {
158
+ // Can be replaced with TypeKit once #6976 is implemented
159
+ const {
160
+ ObjectValue
161
+ } = await Tester.compile(t.code`
162
+ @example(#{})
163
+ model ${t.model("ObjectValue")} {};
164
+ `);
165
+ const value = getExampleValue(ObjectValue);
166
+ await testValueExpression(value, `{}`);
167
+ });
168
+ it("object with properties", async () => {
169
+ // Can be replaced with TypeKit once #6976 is implemented
170
+ const {
171
+ ObjectValue
172
+ } = await Tester.compile(t.code`
173
+ @example(#{aNumber: 5, aString: "foo", aBoolean: true})
174
+ model ${t.model("ObjectValue")} {
175
+ ${t.modelProperty("aNumber")}: int32;
176
+ ${t.modelProperty("aString")}: string;
177
+ ${t.modelProperty("aBoolean")}: boolean;
178
+ };
179
+ `);
180
+ const value = getExampleValue(ObjectValue);
181
+ await testValueExpression(value, `{"aNumber": 5, "aString": "foo", "aBoolean": True}`);
182
+ });
183
+ });
184
+ describe("EnumValue", () => {
185
+ it("different EnumValue types", async () => {
186
+ // Can be replaced with TypeKit once #6976 is implemented
187
+ const {
188
+ Red,
189
+ Green,
190
+ Blue
191
+ } = await Tester.compile(t.code`
192
+ enum ${t.enum("Color")} {
193
+ Red,
194
+ Green: 3,
195
+ Blue: "cyan",
196
+ }
197
+ const ${t.value("Red")} = ${t.enumValue("Color.Red")};
198
+ const ${t.value("Green")} = ${t.enumValue("Color.Green")};
199
+ const ${t.value("Blue")} = ${t.enumValue("Color.Blue")};
200
+ `);
201
+ await testValueExpression(Red, `"Red"`);
202
+ await testValueExpression(Green, `3`);
203
+ await testValueExpression(Blue, `"cyan"`);
204
+ });
205
+ });
206
+
207
+ /**
208
+ * Helper that renders a value expression and checks the output against the expected value.
209
+ */
210
+ async function testValueExpression(value, expected) {
211
+ expect(getOutput(program, [_$createComponent(Atom, {
212
+ value: value
213
+ })])).toRenderTo(`${expected}`);
214
+ }
215
+
216
+ /**
217
+ * Extracts the value marked with the @example decorator from a model.
218
+ */
219
+ function getExampleValue(model) {
220
+ const decorator = model?.decorators.find(d => d.definition?.name === "@example");
221
+ assert.exists(decorator?.args[0]?.value, "unable to find example decorator");
222
+ return decorator.args[0].value;
223
+ }
224
+ //# sourceMappingURL=atom.test.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"names":["getOutput","Tester","t","$","assert","beforeAll","describe","expect","it","Atom","program","result","compile","value","entityKind","valueKind","testValueExpression","createString","createBoolean","createNumeric","fractional","_$createComponent","float","toRenderTo","values","minDate","code","model","modelProperty","type","defaultValue","IpAddress","scalar","getExampleValue","rejects","toThrow","ObjectValue","Red","Green","Blue","enum","enumValue","expected","decorator","decorators","find","d","definition","name","exists","args"],"sources":["../../../../../src/python/components/atom/atom.test.tsx"],"sourcesContent":[null],"mappings":";AAAA,SAASA,SAAS,QAAQ,uBAAuB;AACjD,SAASC,MAAM,QAAQ,oBAAoB;AAE3C,SAASC,CAAC,QAAQ,4BAA4B;AAC9C,SAASC,CAAC,QAAQ,4BAA4B;AAC9C,SAASC,MAAM,EAAEC,SAAS,EAAEC,QAAQ,EAAEC,MAAM,EAAEC,EAAE,QAAQ,QAAQ;AAChE,SAASC,IAAI,QAAQ,gBAAgB;AAErC,IAAIC,OAAgB;AAEpBL,SAAS,CAAC,YAAY;EACpB,MAAMM,MAAM,GAAG,MAAMV,MAAM,CAACW,OAAO,CAAC,EAAE,CAAC;EACvCF,OAAO,GAAGC,MAAM,CAACD,OAAO;AAC1B,CAAC,CAAC;AAEFJ,QAAQ,CAAC,WAAW,EAAE,MAAM;EAC1BE,EAAE,CAAC,YAAY,EAAE,YAAY;IAC3B,MAAMK,KAAK,GAAG;MAAEC,UAAU,EAAE,OAAO;MAAEC,SAAS,EAAE,WAAW;MAAEF,KAAK,EAAE;IAAK,CAAU;IAEnF,MAAMG,mBAAmB,CAACH,KAAK,EAAE,MAAM,CAAC;EAC1C,CAAC,CAAC;AACJ,CAAC,CAAC;AAEFP,QAAQ,CAAC,aAAa,EAAE,MAAM;EAC5BE,EAAE,CAAC,eAAe,EAAE,YAAY;IAC9B,MAAMK,KAAK,GAAGV,CAAC,CAACO,OAAO,CAAC,CAACG,KAAK,CAACI,YAAY,CAAC,MAAM,CAAC;IAEnD,MAAMD,mBAAmB,CAACH,KAAK,EAAE,QAAQ,CAAC;EAC5C,CAAC,CAAC;EAEFL,EAAE,CAAC,cAAc,EAAE,YAAY;IAC7B,MAAMK,KAAK,GAAGV,CAAC,CAACO,OAAO,CAAC,CAACG,KAAK,CAACI,YAAY,CAAC,EAAE,CAAC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AU,EAAEC,IAAI,KAAK,UAAU,CAAC;EAClF5C,MAAM,CAAC6C,MAAM,CAACN,SAAS,EAAEO,IAAI,CAAC,CAAC,CAAC,EAAErC,KAAK,EAAE,kCAAkC,CAAC;EAC5E,OAAO8B,SAAS,CAACO,IAAI,CAAC,CAAC,CAAC,CAACrC,KAAK;AAChC","ignoreList":[]}
@@ -0,0 +1,2 @@
1
+ export * from "./atom.js";
2
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/python/components/atom/index.ts"],"names":[],"mappings":"AAAA,cAAc,WAAW,CAAC"}
@@ -0,0 +1,2 @@
1
+ export * from "./atom.js";
2
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"names":[],"sources":["../../../../../src/python/components/atom/index.ts"],"sourcesContent":[null],"mappings":"AAAA,cAAc,WAAW","ignoreList":[]}