@kuncat/avoidant 0.2.3 → 0.2.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 (87) hide show
  1. package/dist/components/AvoidantGame.svelte +1 -2
  2. package/dist/components/MapControls.svelte +1 -1
  3. package/dist/components/board.svelte +7 -34
  4. package/dist/components/label-connectors.d.ts +5 -2
  5. package/dist/components/label-connectors.js +47 -37
  6. package/dist/components/map-camera.js +1 -1
  7. package/dist/paraglide/messages/_index.d.ts +8 -8
  8. package/dist/paraglide/messages/_index.js +9 -9
  9. package/dist/paraglide/messages/action_back.js +2 -2
  10. package/dist/paraglide/messages/action_copy.js +2 -2
  11. package/dist/paraglide/messages/action_exit.js +2 -2
  12. package/dist/paraglide/messages/action_invite.js +2 -2
  13. package/dist/paraglide/messages/action_join.js +2 -2
  14. package/dist/paraglide/messages/action_join_game.js +2 -2
  15. package/dist/paraglide/messages/action_new_game.js +2 -2
  16. package/dist/paraglide/messages/action_random.js +2 -2
  17. package/dist/paraglide/messages/action_start.js +2 -2
  18. package/dist/paraglide/messages/aria_close_invitation.js +2 -2
  19. package/dist/paraglide/messages/aria_score_summary.js +2 -2
  20. package/dist/paraglide/messages/cells_count.js +2 -2
  21. package/dist/paraglide/messages/cells_per_face.js +2 -2
  22. package/dist/paraglide/messages/default_player_name.js +2 -2
  23. package/dist/paraglide/messages/error_join_connect_failed.js +2 -2
  24. package/dist/paraglide/messages/error_join_failed.js +2 -2
  25. package/dist/paraglide/messages/error_join_ticket_invalid.js +2 -2
  26. package/dist/paraglide/messages/error_join_ticket_required.js +2 -2
  27. package/dist/paraglide/messages/faces_count.js +2 -2
  28. package/dist/paraglide/messages/field_cell_density.js +2 -2
  29. package/dist/paraglide/messages/field_invitation_url.js +2 -2
  30. package/dist/paraglide/messages/field_map_shape.js +2 -2
  31. package/dist/paraglide/messages/field_map_size.js +2 -2
  32. package/dist/paraglide/messages/field_player_name.js +2 -2
  33. package/dist/paraglide/messages/field_radius.js +2 -2
  34. package/dist/paraglide/messages/field_radius_x.js +2 -2
  35. package/dist/paraglide/messages/field_radius_y.js +2 -2
  36. package/dist/paraglide/messages/field_radius_z.js +2 -2
  37. package/dist/paraglide/messages/field_relay_servers.js +2 -2
  38. package/dist/paraglide/messages/field_seed.js +2 -2
  39. package/dist/paraglide/messages/field_size.js +2 -2
  40. package/dist/paraglide/messages/field_spikiness.js +2 -2
  41. package/dist/paraglide/messages/field_subdivisions.js +2 -2
  42. package/dist/paraglide/messages/field_surface_detail.js +2 -2
  43. package/dist/paraglide/messages/field_ticket_or_invitation_url.js +2 -2
  44. package/dist/paraglide/messages/field_tutorial_mode.js +2 -2
  45. package/dist/paraglide/messages/field_void_fraction.js +2 -2
  46. package/dist/paraglide/messages/label_advanced_settings.js +2 -2
  47. package/dist/paraglide/messages/label_players.js +2 -2
  48. package/dist/paraglide/messages/label_safe_cells_explored.js +2 -2
  49. package/dist/paraglide/messages/label_safe_cells_remaining.js +2 -2
  50. package/dist/paraglide/messages/label_score.js +2 -2
  51. package/dist/paraglide/messages/label_streak.js +2 -2
  52. package/dist/paraglide/messages/label_voids_discovered.js +2 -2
  53. package/dist/paraglide/messages/package.json +4 -0
  54. package/dist/paraglide/messages/preset_custom.js +2 -2
  55. package/dist/paraglide/messages/preset_large.js +2 -2
  56. package/dist/paraglide/messages/preset_medium.js +2 -2
  57. package/dist/paraglide/messages/preset_small.js +2 -2
  58. package/dist/paraglide/messages/shape_label.js +2 -2
  59. package/dist/paraglide/messages/status_generating_map.js +2 -2
  60. package/dist/paraglide/messages/status_initialization_failed.js +2 -2
  61. package/dist/paraglide/messages/status_joining_game.js +2 -2
  62. package/dist/paraglide/messages/status_loading.js +2 -2
  63. package/dist/paraglide/messages/status_preparing.js +2 -2
  64. package/dist/paraglide/messages/text_avoided.js +2 -2
  65. package/dist/paraglide/messages/text_density_summary.js +2 -2
  66. package/dist/paraglide/messages/text_invite_after_opening.js +2 -2
  67. package/dist/paraglide/messages/text_relay_servers_hint.js +2 -2
  68. package/dist/paraglide/messages/tutorial_action_dismiss.js +2 -2
  69. package/dist/paraglide/messages/tutorial_action_next.js +2 -2
  70. package/dist/paraglide/messages/tutorial_after_safe_deducible.js +2 -2
  71. package/dist/paraglide/messages/tutorial_after_safe_guess.js +2 -2
  72. package/dist/paraglide/messages/tutorial_after_void.js +2 -2
  73. package/dist/paraglide/messages/tutorial_awaiting_first_click.js +2 -2
  74. package/dist/paraglide/messages/tutorial_intro.d.ts +1 -1
  75. package/dist/paraglide/messages/tutorial_intro.js +5 -5
  76. package/dist/paraglide/messages/tutorial_won.js +2 -2
  77. package/dist/paraglide/registry.d.ts +13 -0
  78. package/dist/paraglide/registry.js +15 -0
  79. package/dist/paraglide/runtime.d.ts +90 -26
  80. package/dist/paraglide/runtime.js +597 -109
  81. package/dist/paraglide/server.d.ts +1 -1
  82. package/dist/paraglide/server.js +27 -10
  83. package/dist/wasm/avoidant_wasm.d.ts +46 -1
  84. package/dist/wasm/avoidant_wasm.js +164 -28
  85. package/dist/wasm/avoidant_wasm_bg.wasm +0 -0
  86. package/dist/wasm/avoidant_wasm_bg.wasm.d.ts +15 -1
  87. package/package.json +29 -29
@@ -24,6 +24,6 @@ const bn_field_radius_y = /** @type {(inputs: Field_Radius_YInputs) => Localized
24
24
  */
25
25
  export const field_radius_y = /** @type {((inputs?: Field_Radius_YInputs, options?: { locale?: "en" | "bn" }) => LocalizedString) & import('../runtime.js').MessageMetadata<Field_Radius_YInputs, { locale?: "en" | "bn" }, {}>} */ ((inputs = {}, options = {}) => {
26
26
  const locale = experimentalStaticLocale ?? options.locale ?? getLocale()
27
- if (locale === "en") return en_field_radius_y(inputs)
28
- return bn_field_radius_y(inputs)
27
+ if (locale === "bn") return bn_field_radius_y(inputs)
28
+ return en_field_radius_y(inputs)
29
29
  });
@@ -24,6 +24,6 @@ const bn_field_radius_z = /** @type {(inputs: Field_Radius_ZInputs) => Localized
24
24
  */
25
25
  export const field_radius_z = /** @type {((inputs?: Field_Radius_ZInputs, options?: { locale?: "en" | "bn" }) => LocalizedString) & import('../runtime.js').MessageMetadata<Field_Radius_ZInputs, { locale?: "en" | "bn" }, {}>} */ ((inputs = {}, options = {}) => {
26
26
  const locale = experimentalStaticLocale ?? options.locale ?? getLocale()
27
- if (locale === "en") return en_field_radius_z(inputs)
28
- return bn_field_radius_z(inputs)
27
+ if (locale === "bn") return bn_field_radius_z(inputs)
28
+ return en_field_radius_z(inputs)
29
29
  });
@@ -24,6 +24,6 @@ const bn_field_relay_servers = /** @type {(inputs: Field_Relay_ServersInputs) =>
24
24
  */
25
25
  export const field_relay_servers = /** @type {((inputs?: Field_Relay_ServersInputs, options?: { locale?: "en" | "bn" }) => LocalizedString) & import('../runtime.js').MessageMetadata<Field_Relay_ServersInputs, { locale?: "en" | "bn" }, {}>} */ ((inputs = {}, options = {}) => {
26
26
  const locale = experimentalStaticLocale ?? options.locale ?? getLocale()
27
- if (locale === "en") return en_field_relay_servers(inputs)
28
- return bn_field_relay_servers(inputs)
27
+ if (locale === "bn") return bn_field_relay_servers(inputs)
28
+ return en_field_relay_servers(inputs)
29
29
  });
@@ -24,6 +24,6 @@ const bn_field_seed = /** @type {(inputs: Field_SeedInputs) => LocalizedString}
24
24
  */
25
25
  export const field_seed = /** @type {((inputs?: Field_SeedInputs, options?: { locale?: "en" | "bn" }) => LocalizedString) & import('../runtime.js').MessageMetadata<Field_SeedInputs, { locale?: "en" | "bn" }, {}>} */ ((inputs = {}, options = {}) => {
26
26
  const locale = experimentalStaticLocale ?? options.locale ?? getLocale()
27
- if (locale === "en") return en_field_seed(inputs)
28
- return bn_field_seed(inputs)
27
+ if (locale === "bn") return bn_field_seed(inputs)
28
+ return en_field_seed(inputs)
29
29
  });
@@ -24,6 +24,6 @@ const bn_field_size = /** @type {(inputs: Field_SizeInputs) => LocalizedString}
24
24
  */
25
25
  export const field_size = /** @type {((inputs?: Field_SizeInputs, options?: { locale?: "en" | "bn" }) => LocalizedString) & import('../runtime.js').MessageMetadata<Field_SizeInputs, { locale?: "en" | "bn" }, {}>} */ ((inputs = {}, options = {}) => {
26
26
  const locale = experimentalStaticLocale ?? options.locale ?? getLocale()
27
- if (locale === "en") return en_field_size(inputs)
28
- return bn_field_size(inputs)
27
+ if (locale === "bn") return bn_field_size(inputs)
28
+ return en_field_size(inputs)
29
29
  });
@@ -24,6 +24,6 @@ const bn_field_spikiness = /** @type {(inputs: Field_SpikinessInputs) => Localiz
24
24
  */
25
25
  export const field_spikiness = /** @type {((inputs?: Field_SpikinessInputs, options?: { locale?: "en" | "bn" }) => LocalizedString) & import('../runtime.js').MessageMetadata<Field_SpikinessInputs, { locale?: "en" | "bn" }, {}>} */ ((inputs = {}, options = {}) => {
26
26
  const locale = experimentalStaticLocale ?? options.locale ?? getLocale()
27
- if (locale === "en") return en_field_spikiness(inputs)
28
- return bn_field_spikiness(inputs)
27
+ if (locale === "bn") return bn_field_spikiness(inputs)
28
+ return en_field_spikiness(inputs)
29
29
  });
@@ -24,6 +24,6 @@ const bn_field_subdivisions = /** @type {(inputs: Field_SubdivisionsInputs) => L
24
24
  */
25
25
  export const field_subdivisions = /** @type {((inputs?: Field_SubdivisionsInputs, options?: { locale?: "en" | "bn" }) => LocalizedString) & import('../runtime.js').MessageMetadata<Field_SubdivisionsInputs, { locale?: "en" | "bn" }, {}>} */ ((inputs = {}, options = {}) => {
26
26
  const locale = experimentalStaticLocale ?? options.locale ?? getLocale()
27
- if (locale === "en") return en_field_subdivisions(inputs)
28
- return bn_field_subdivisions(inputs)
27
+ if (locale === "bn") return bn_field_subdivisions(inputs)
28
+ return en_field_subdivisions(inputs)
29
29
  });
@@ -24,6 +24,6 @@ const bn_field_surface_detail = /** @type {(inputs: Field_Surface_DetailInputs)
24
24
  */
25
25
  export const field_surface_detail = /** @type {((inputs?: Field_Surface_DetailInputs, options?: { locale?: "en" | "bn" }) => LocalizedString) & import('../runtime.js').MessageMetadata<Field_Surface_DetailInputs, { locale?: "en" | "bn" }, {}>} */ ((inputs = {}, options = {}) => {
26
26
  const locale = experimentalStaticLocale ?? options.locale ?? getLocale()
27
- if (locale === "en") return en_field_surface_detail(inputs)
28
- return bn_field_surface_detail(inputs)
27
+ if (locale === "bn") return bn_field_surface_detail(inputs)
28
+ return en_field_surface_detail(inputs)
29
29
  });
@@ -24,6 +24,6 @@ const bn_field_ticket_or_invitation_url = /** @type {(inputs: Field_Ticket_Or_In
24
24
  */
25
25
  export const field_ticket_or_invitation_url = /** @type {((inputs?: Field_Ticket_Or_Invitation_UrlInputs, options?: { locale?: "en" | "bn" }) => LocalizedString) & import('../runtime.js').MessageMetadata<Field_Ticket_Or_Invitation_UrlInputs, { locale?: "en" | "bn" }, {}>} */ ((inputs = {}, options = {}) => {
26
26
  const locale = experimentalStaticLocale ?? options.locale ?? getLocale()
27
- if (locale === "en") return en_field_ticket_or_invitation_url(inputs)
28
- return bn_field_ticket_or_invitation_url(inputs)
27
+ if (locale === "bn") return bn_field_ticket_or_invitation_url(inputs)
28
+ return en_field_ticket_or_invitation_url(inputs)
29
29
  });
@@ -24,6 +24,6 @@ const bn_field_tutorial_mode = /** @type {(inputs: Field_Tutorial_ModeInputs) =>
24
24
  */
25
25
  export const field_tutorial_mode = /** @type {((inputs?: Field_Tutorial_ModeInputs, options?: { locale?: "en" | "bn" }) => LocalizedString) & import('../runtime.js').MessageMetadata<Field_Tutorial_ModeInputs, { locale?: "en" | "bn" }, {}>} */ ((inputs = {}, options = {}) => {
26
26
  const locale = experimentalStaticLocale ?? options.locale ?? getLocale()
27
- if (locale === "en") return en_field_tutorial_mode(inputs)
28
- return bn_field_tutorial_mode(inputs)
27
+ if (locale === "bn") return bn_field_tutorial_mode(inputs)
28
+ return en_field_tutorial_mode(inputs)
29
29
  });
@@ -24,6 +24,6 @@ const bn_field_void_fraction = /** @type {(inputs: Field_Void_FractionInputs) =>
24
24
  */
25
25
  export const field_void_fraction = /** @type {((inputs?: Field_Void_FractionInputs, options?: { locale?: "en" | "bn" }) => LocalizedString) & import('../runtime.js').MessageMetadata<Field_Void_FractionInputs, { locale?: "en" | "bn" }, {}>} */ ((inputs = {}, options = {}) => {
26
26
  const locale = experimentalStaticLocale ?? options.locale ?? getLocale()
27
- if (locale === "en") return en_field_void_fraction(inputs)
28
- return bn_field_void_fraction(inputs)
27
+ if (locale === "bn") return bn_field_void_fraction(inputs)
28
+ return en_field_void_fraction(inputs)
29
29
  });
@@ -24,6 +24,6 @@ const bn_label_advanced_settings = /** @type {(inputs: Label_Advanced_SettingsIn
24
24
  */
25
25
  export const label_advanced_settings = /** @type {((inputs?: Label_Advanced_SettingsInputs, options?: { locale?: "en" | "bn" }) => LocalizedString) & import('../runtime.js').MessageMetadata<Label_Advanced_SettingsInputs, { locale?: "en" | "bn" }, {}>} */ ((inputs = {}, options = {}) => {
26
26
  const locale = experimentalStaticLocale ?? options.locale ?? getLocale()
27
- if (locale === "en") return en_label_advanced_settings(inputs)
28
- return bn_label_advanced_settings(inputs)
27
+ if (locale === "bn") return bn_label_advanced_settings(inputs)
28
+ return en_label_advanced_settings(inputs)
29
29
  });
@@ -30,6 +30,6 @@ const bn_label_players = /** @type {(inputs: Label_PlayersInputs) => LocalizedSt
30
30
  */
31
31
  export const label_players = /** @type {((inputs: Label_PlayersInputs, options?: { locale?: "en" | "bn" }) => LocalizedString) & import('../runtime.js').MessageMetadata<Label_PlayersInputs, { locale?: "en" | "bn" }, {}>} */ ((inputs, options = {}) => {
32
32
  const locale = experimentalStaticLocale ?? options.locale ?? getLocale()
33
- if (locale === "en") return en_label_players(inputs)
34
- return bn_label_players(inputs)
33
+ if (locale === "bn") return bn_label_players(inputs)
34
+ return en_label_players(inputs)
35
35
  });
@@ -30,6 +30,6 @@ const bn_label_safe_cells_explored = /** @type {(inputs: Label_Safe_Cells_Explor
30
30
  */
31
31
  export const label_safe_cells_explored = /** @type {((inputs: Label_Safe_Cells_ExploredInputs, options?: { locale?: "en" | "bn" }) => LocalizedString) & import('../runtime.js').MessageMetadata<Label_Safe_Cells_ExploredInputs, { locale?: "en" | "bn" }, {}>} */ ((inputs, options = {}) => {
32
32
  const locale = experimentalStaticLocale ?? options.locale ?? getLocale()
33
- if (locale === "en") return en_label_safe_cells_explored(inputs)
34
- return bn_label_safe_cells_explored(inputs)
33
+ if (locale === "bn") return bn_label_safe_cells_explored(inputs)
34
+ return en_label_safe_cells_explored(inputs)
35
35
  });
@@ -30,6 +30,6 @@ const bn_label_safe_cells_remaining = /** @type {(inputs: Label_Safe_Cells_Remai
30
30
  */
31
31
  export const label_safe_cells_remaining = /** @type {((inputs: Label_Safe_Cells_RemainingInputs, options?: { locale?: "en" | "bn" }) => LocalizedString) & import('../runtime.js').MessageMetadata<Label_Safe_Cells_RemainingInputs, { locale?: "en" | "bn" }, {}>} */ ((inputs, options = {}) => {
32
32
  const locale = experimentalStaticLocale ?? options.locale ?? getLocale()
33
- if (locale === "en") return en_label_safe_cells_remaining(inputs)
34
- return bn_label_safe_cells_remaining(inputs)
33
+ if (locale === "bn") return bn_label_safe_cells_remaining(inputs)
34
+ return en_label_safe_cells_remaining(inputs)
35
35
  });
@@ -24,6 +24,6 @@ const bn_label_score = /** @type {(inputs: Label_ScoreInputs) => LocalizedString
24
24
  */
25
25
  export const label_score = /** @type {((inputs?: Label_ScoreInputs, options?: { locale?: "en" | "bn" }) => LocalizedString) & import('../runtime.js').MessageMetadata<Label_ScoreInputs, { locale?: "en" | "bn" }, {}>} */ ((inputs = {}, options = {}) => {
26
26
  const locale = experimentalStaticLocale ?? options.locale ?? getLocale()
27
- if (locale === "en") return en_label_score(inputs)
28
- return bn_label_score(inputs)
27
+ if (locale === "bn") return bn_label_score(inputs)
28
+ return en_label_score(inputs)
29
29
  });
@@ -24,6 +24,6 @@ const bn_label_streak = /** @type {(inputs: Label_StreakInputs) => LocalizedStri
24
24
  */
25
25
  export const label_streak = /** @type {((inputs?: Label_StreakInputs, options?: { locale?: "en" | "bn" }) => LocalizedString) & import('../runtime.js').MessageMetadata<Label_StreakInputs, { locale?: "en" | "bn" }, {}>} */ ((inputs = {}, options = {}) => {
26
26
  const locale = experimentalStaticLocale ?? options.locale ?? getLocale()
27
- if (locale === "en") return en_label_streak(inputs)
28
- return bn_label_streak(inputs)
27
+ if (locale === "bn") return bn_label_streak(inputs)
28
+ return en_label_streak(inputs)
29
29
  });
@@ -24,6 +24,6 @@ const bn_label_voids_discovered = /** @type {(inputs: Label_Voids_DiscoveredInpu
24
24
  */
25
25
  export const label_voids_discovered = /** @type {((inputs?: Label_Voids_DiscoveredInputs, options?: { locale?: "en" | "bn" }) => LocalizedString) & import('../runtime.js').MessageMetadata<Label_Voids_DiscoveredInputs, { locale?: "en" | "bn" }, {}>} */ ((inputs = {}, options = {}) => {
26
26
  const locale = experimentalStaticLocale ?? options.locale ?? getLocale()
27
- if (locale === "en") return en_label_voids_discovered(inputs)
28
- return bn_label_voids_discovered(inputs)
27
+ if (locale === "bn") return bn_label_voids_discovered(inputs)
28
+ return en_label_voids_discovered(inputs)
29
29
  });
@@ -0,0 +1,4 @@
1
+ {
2
+ "type": "module",
3
+ "sideEffects": false
4
+ }
@@ -24,6 +24,6 @@ const bn_preset_custom = /** @type {(inputs: Preset_CustomInputs) => LocalizedSt
24
24
  */
25
25
  export const preset_custom = /** @type {((inputs?: Preset_CustomInputs, options?: { locale?: "en" | "bn" }) => LocalizedString) & import('../runtime.js').MessageMetadata<Preset_CustomInputs, { locale?: "en" | "bn" }, {}>} */ ((inputs = {}, options = {}) => {
26
26
  const locale = experimentalStaticLocale ?? options.locale ?? getLocale()
27
- if (locale === "en") return en_preset_custom(inputs)
28
- return bn_preset_custom(inputs)
27
+ if (locale === "bn") return bn_preset_custom(inputs)
28
+ return en_preset_custom(inputs)
29
29
  });
@@ -24,6 +24,6 @@ const bn_preset_large = /** @type {(inputs: Preset_LargeInputs) => LocalizedStri
24
24
  */
25
25
  export const preset_large = /** @type {((inputs?: Preset_LargeInputs, options?: { locale?: "en" | "bn" }) => LocalizedString) & import('../runtime.js').MessageMetadata<Preset_LargeInputs, { locale?: "en" | "bn" }, {}>} */ ((inputs = {}, options = {}) => {
26
26
  const locale = experimentalStaticLocale ?? options.locale ?? getLocale()
27
- if (locale === "en") return en_preset_large(inputs)
28
- return bn_preset_large(inputs)
27
+ if (locale === "bn") return bn_preset_large(inputs)
28
+ return en_preset_large(inputs)
29
29
  });
@@ -24,6 +24,6 @@ const bn_preset_medium = /** @type {(inputs: Preset_MediumInputs) => LocalizedSt
24
24
  */
25
25
  export const preset_medium = /** @type {((inputs?: Preset_MediumInputs, options?: { locale?: "en" | "bn" }) => LocalizedString) & import('../runtime.js').MessageMetadata<Preset_MediumInputs, { locale?: "en" | "bn" }, {}>} */ ((inputs = {}, options = {}) => {
26
26
  const locale = experimentalStaticLocale ?? options.locale ?? getLocale()
27
- if (locale === "en") return en_preset_medium(inputs)
28
- return bn_preset_medium(inputs)
27
+ if (locale === "bn") return bn_preset_medium(inputs)
28
+ return en_preset_medium(inputs)
29
29
  });
@@ -24,6 +24,6 @@ const bn_preset_small = /** @type {(inputs: Preset_SmallInputs) => LocalizedStri
24
24
  */
25
25
  export const preset_small = /** @type {((inputs?: Preset_SmallInputs, options?: { locale?: "en" | "bn" }) => LocalizedString) & import('../runtime.js').MessageMetadata<Preset_SmallInputs, { locale?: "en" | "bn" }, {}>} */ ((inputs = {}, options = {}) => {
26
26
  const locale = experimentalStaticLocale ?? options.locale ?? getLocale()
27
- if (locale === "en") return en_preset_small(inputs)
28
- return bn_preset_small(inputs)
27
+ if (locale === "bn") return bn_preset_small(inputs)
28
+ return en_preset_small(inputs)
29
29
  });
@@ -50,6 +50,6 @@ const bn_shape_label = /** @type {(inputs: Shape_LabelInputs) => LocalizedString
50
50
  */
51
51
  export const shape_label = /** @type {((inputs: Shape_LabelInputs, options?: { locale?: "en" | "bn" }) => LocalizedString) & import('../runtime.js').MessageMetadata<Shape_LabelInputs, { locale?: "en" | "bn" }, {}>} */ ((inputs, options = {}) => {
52
52
  const locale = experimentalStaticLocale ?? options.locale ?? getLocale()
53
- if (locale === "en") return en_shape_label(inputs)
54
- return bn_shape_label(inputs)
53
+ if (locale === "bn") return bn_shape_label(inputs)
54
+ return en_shape_label(inputs)
55
55
  });
@@ -24,6 +24,6 @@ const bn_status_generating_map = /** @type {(inputs: Status_Generating_MapInputs
24
24
  */
25
25
  export const status_generating_map = /** @type {((inputs?: Status_Generating_MapInputs, options?: { locale?: "en" | "bn" }) => LocalizedString) & import('../runtime.js').MessageMetadata<Status_Generating_MapInputs, { locale?: "en" | "bn" }, {}>} */ ((inputs = {}, options = {}) => {
26
26
  const locale = experimentalStaticLocale ?? options.locale ?? getLocale()
27
- if (locale === "en") return en_status_generating_map(inputs)
28
- return bn_status_generating_map(inputs)
27
+ if (locale === "bn") return bn_status_generating_map(inputs)
28
+ return en_status_generating_map(inputs)
29
29
  });
@@ -24,6 +24,6 @@ const bn_status_initialization_failed = /** @type {(inputs: Status_Initializatio
24
24
  */
25
25
  export const status_initialization_failed = /** @type {((inputs?: Status_Initialization_FailedInputs, options?: { locale?: "en" | "bn" }) => LocalizedString) & import('../runtime.js').MessageMetadata<Status_Initialization_FailedInputs, { locale?: "en" | "bn" }, {}>} */ ((inputs = {}, options = {}) => {
26
26
  const locale = experimentalStaticLocale ?? options.locale ?? getLocale()
27
- if (locale === "en") return en_status_initialization_failed(inputs)
28
- return bn_status_initialization_failed(inputs)
27
+ if (locale === "bn") return bn_status_initialization_failed(inputs)
28
+ return en_status_initialization_failed(inputs)
29
29
  });
@@ -24,6 +24,6 @@ const bn_status_joining_game = /** @type {(inputs: Status_Joining_GameInputs) =>
24
24
  */
25
25
  export const status_joining_game = /** @type {((inputs?: Status_Joining_GameInputs, options?: { locale?: "en" | "bn" }) => LocalizedString) & import('../runtime.js').MessageMetadata<Status_Joining_GameInputs, { locale?: "en" | "bn" }, {}>} */ ((inputs = {}, options = {}) => {
26
26
  const locale = experimentalStaticLocale ?? options.locale ?? getLocale()
27
- if (locale === "en") return en_status_joining_game(inputs)
28
- return bn_status_joining_game(inputs)
27
+ if (locale === "bn") return bn_status_joining_game(inputs)
28
+ return en_status_joining_game(inputs)
29
29
  });
@@ -24,6 +24,6 @@ const bn_status_loading = /** @type {(inputs: Status_LoadingInputs) => Localized
24
24
  */
25
25
  export const status_loading = /** @type {((inputs?: Status_LoadingInputs, options?: { locale?: "en" | "bn" }) => LocalizedString) & import('../runtime.js').MessageMetadata<Status_LoadingInputs, { locale?: "en" | "bn" }, {}>} */ ((inputs = {}, options = {}) => {
26
26
  const locale = experimentalStaticLocale ?? options.locale ?? getLocale()
27
- if (locale === "en") return en_status_loading(inputs)
28
- return bn_status_loading(inputs)
27
+ if (locale === "bn") return bn_status_loading(inputs)
28
+ return en_status_loading(inputs)
29
29
  });
@@ -24,6 +24,6 @@ const bn_status_preparing = /** @type {(inputs: Status_PreparingInputs) => Local
24
24
  */
25
25
  export const status_preparing = /** @type {((inputs?: Status_PreparingInputs, options?: { locale?: "en" | "bn" }) => LocalizedString) & import('../runtime.js').MessageMetadata<Status_PreparingInputs, { locale?: "en" | "bn" }, {}>} */ ((inputs = {}, options = {}) => {
26
26
  const locale = experimentalStaticLocale ?? options.locale ?? getLocale()
27
- if (locale === "en") return en_status_preparing(inputs)
28
- return bn_status_preparing(inputs)
27
+ if (locale === "bn") return bn_status_preparing(inputs)
28
+ return en_status_preparing(inputs)
29
29
  });
@@ -24,6 +24,6 @@ const bn_text_avoided = /** @type {(inputs: Text_AvoidedInputs) => LocalizedStri
24
24
  */
25
25
  export const text_avoided = /** @type {((inputs?: Text_AvoidedInputs, options?: { locale?: "en" | "bn" }) => LocalizedString) & import('../runtime.js').MessageMetadata<Text_AvoidedInputs, { locale?: "en" | "bn" }, {}>} */ ((inputs = {}, options = {}) => {
26
26
  const locale = experimentalStaticLocale ?? options.locale ?? getLocale()
27
- if (locale === "en") return en_text_avoided(inputs)
28
- return bn_text_avoided(inputs)
27
+ if (locale === "bn") return bn_text_avoided(inputs)
28
+ return en_text_avoided(inputs)
29
29
  });
@@ -24,6 +24,6 @@ const bn_text_density_summary = /** @type {(inputs: Text_Density_SummaryInputs)
24
24
  */
25
25
  export const text_density_summary = /** @type {((inputs: Text_Density_SummaryInputs, options?: { locale?: "en" | "bn" }) => LocalizedString) & import('../runtime.js').MessageMetadata<Text_Density_SummaryInputs, { locale?: "en" | "bn" }, {}>} */ ((inputs, options = {}) => {
26
26
  const locale = experimentalStaticLocale ?? options.locale ?? getLocale()
27
- if (locale === "en") return en_text_density_summary(inputs)
28
- return bn_text_density_summary(inputs)
27
+ if (locale === "bn") return bn_text_density_summary(inputs)
28
+ return en_text_density_summary(inputs)
29
29
  });
@@ -24,6 +24,6 @@ const bn_text_invite_after_opening = /** @type {(inputs: Text_Invite_After_Openi
24
24
  */
25
25
  export const text_invite_after_opening = /** @type {((inputs?: Text_Invite_After_OpeningInputs, options?: { locale?: "en" | "bn" }) => LocalizedString) & import('../runtime.js').MessageMetadata<Text_Invite_After_OpeningInputs, { locale?: "en" | "bn" }, {}>} */ ((inputs = {}, options = {}) => {
26
26
  const locale = experimentalStaticLocale ?? options.locale ?? getLocale()
27
- if (locale === "en") return en_text_invite_after_opening(inputs)
28
- return bn_text_invite_after_opening(inputs)
27
+ if (locale === "bn") return bn_text_invite_after_opening(inputs)
28
+ return en_text_invite_after_opening(inputs)
29
29
  });
@@ -24,6 +24,6 @@ const bn_text_relay_servers_hint = /** @type {(inputs: Text_Relay_Servers_HintIn
24
24
  */
25
25
  export const text_relay_servers_hint = /** @type {((inputs?: Text_Relay_Servers_HintInputs, options?: { locale?: "en" | "bn" }) => LocalizedString) & import('../runtime.js').MessageMetadata<Text_Relay_Servers_HintInputs, { locale?: "en" | "bn" }, {}>} */ ((inputs = {}, options = {}) => {
26
26
  const locale = experimentalStaticLocale ?? options.locale ?? getLocale()
27
- if (locale === "en") return en_text_relay_servers_hint(inputs)
28
- return bn_text_relay_servers_hint(inputs)
27
+ if (locale === "bn") return bn_text_relay_servers_hint(inputs)
28
+ return en_text_relay_servers_hint(inputs)
29
29
  });
@@ -24,6 +24,6 @@ const bn_tutorial_action_dismiss = /** @type {(inputs: Tutorial_Action_DismissIn
24
24
  */
25
25
  export const tutorial_action_dismiss = /** @type {((inputs?: Tutorial_Action_DismissInputs, options?: { locale?: "en" | "bn" }) => LocalizedString) & import('../runtime.js').MessageMetadata<Tutorial_Action_DismissInputs, { locale?: "en" | "bn" }, {}>} */ ((inputs = {}, options = {}) => {
26
26
  const locale = experimentalStaticLocale ?? options.locale ?? getLocale()
27
- if (locale === "en") return en_tutorial_action_dismiss(inputs)
28
- return bn_tutorial_action_dismiss(inputs)
27
+ if (locale === "bn") return bn_tutorial_action_dismiss(inputs)
28
+ return en_tutorial_action_dismiss(inputs)
29
29
  });
@@ -24,6 +24,6 @@ const bn_tutorial_action_next = /** @type {(inputs: Tutorial_Action_NextInputs)
24
24
  */
25
25
  export const tutorial_action_next = /** @type {((inputs?: Tutorial_Action_NextInputs, options?: { locale?: "en" | "bn" }) => LocalizedString) & import('../runtime.js').MessageMetadata<Tutorial_Action_NextInputs, { locale?: "en" | "bn" }, {}>} */ ((inputs = {}, options = {}) => {
26
26
  const locale = experimentalStaticLocale ?? options.locale ?? getLocale()
27
- if (locale === "en") return en_tutorial_action_next(inputs)
28
- return bn_tutorial_action_next(inputs)
27
+ if (locale === "bn") return bn_tutorial_action_next(inputs)
28
+ return en_tutorial_action_next(inputs)
29
29
  });
@@ -24,6 +24,6 @@ const bn_tutorial_after_safe_deducible = /** @type {(inputs: Tutorial_After_Safe
24
24
  */
25
25
  export const tutorial_after_safe_deducible = /** @type {((inputs?: Tutorial_After_Safe_DeducibleInputs, options?: { locale?: "en" | "bn" }) => LocalizedString) & import('../runtime.js').MessageMetadata<Tutorial_After_Safe_DeducibleInputs, { locale?: "en" | "bn" }, {}>} */ ((inputs = {}, options = {}) => {
26
26
  const locale = experimentalStaticLocale ?? options.locale ?? getLocale()
27
- if (locale === "en") return en_tutorial_after_safe_deducible(inputs)
28
- return bn_tutorial_after_safe_deducible(inputs)
27
+ if (locale === "bn") return bn_tutorial_after_safe_deducible(inputs)
28
+ return en_tutorial_after_safe_deducible(inputs)
29
29
  });
@@ -24,6 +24,6 @@ const bn_tutorial_after_safe_guess = /** @type {(inputs: Tutorial_After_Safe_Gue
24
24
  */
25
25
  export const tutorial_after_safe_guess = /** @type {((inputs?: Tutorial_After_Safe_GuessInputs, options?: { locale?: "en" | "bn" }) => LocalizedString) & import('../runtime.js').MessageMetadata<Tutorial_After_Safe_GuessInputs, { locale?: "en" | "bn" }, {}>} */ ((inputs = {}, options = {}) => {
26
26
  const locale = experimentalStaticLocale ?? options.locale ?? getLocale()
27
- if (locale === "en") return en_tutorial_after_safe_guess(inputs)
28
- return bn_tutorial_after_safe_guess(inputs)
27
+ if (locale === "bn") return bn_tutorial_after_safe_guess(inputs)
28
+ return en_tutorial_after_safe_guess(inputs)
29
29
  });
@@ -24,6 +24,6 @@ const bn_tutorial_after_void = /** @type {(inputs: Tutorial_After_VoidInputs) =>
24
24
  */
25
25
  export const tutorial_after_void = /** @type {((inputs?: Tutorial_After_VoidInputs, options?: { locale?: "en" | "bn" }) => LocalizedString) & import('../runtime.js').MessageMetadata<Tutorial_After_VoidInputs, { locale?: "en" | "bn" }, {}>} */ ((inputs = {}, options = {}) => {
26
26
  const locale = experimentalStaticLocale ?? options.locale ?? getLocale()
27
- if (locale === "en") return en_tutorial_after_void(inputs)
28
- return bn_tutorial_after_void(inputs)
27
+ if (locale === "bn") return bn_tutorial_after_void(inputs)
28
+ return en_tutorial_after_void(inputs)
29
29
  });
@@ -24,6 +24,6 @@ const bn_tutorial_awaiting_first_click = /** @type {(inputs: Tutorial_Awaiting_F
24
24
  */
25
25
  export const tutorial_awaiting_first_click = /** @type {((inputs?: Tutorial_Awaiting_First_ClickInputs, options?: { locale?: "en" | "bn" }) => LocalizedString) & import('../runtime.js').MessageMetadata<Tutorial_Awaiting_First_ClickInputs, { locale?: "en" | "bn" }, {}>} */ ((inputs = {}, options = {}) => {
26
26
  const locale = experimentalStaticLocale ?? options.locale ?? getLocale()
27
- if (locale === "en") return en_tutorial_awaiting_first_click(inputs)
28
- return bn_tutorial_awaiting_first_click(inputs)
27
+ if (locale === "bn") return bn_tutorial_awaiting_first_click(inputs)
28
+ return en_tutorial_awaiting_first_click(inputs)
29
29
  });
@@ -1,7 +1,7 @@
1
1
  /**
2
2
  * | output |
3
3
  * | --- |
4
- * | "Welcome to Avoidant. On any map, drag with one finger or either mouse button to pan. Hold Shift while dragging, or drag with two fingers on a touchscreen, to..." |
4
+ * | "Welcome to Avoidant. On any map, drag with one finger or the left mouse button to pan. Drag with the right mouse button, hold Shift while dragging with the l..." |
5
5
  *
6
6
  * @param {Tutorial_IntroInputs} inputs
7
7
  * @param {{ locale?: "en" | "bn" }} options
@@ -6,17 +6,17 @@ import { getLocale, experimentalStaticLocale } from '../runtime.js';
6
6
  /** @typedef {{}} Tutorial_IntroInputs */
7
7
 
8
8
  const en_tutorial_intro = /** @type {(inputs: Tutorial_IntroInputs) => LocalizedString} */ () => {
9
- return /** @type {LocalizedString} */ (`Welcome to Avoidant. On any map, drag with one finger or either mouse button to pan. Hold Shift while dragging, or drag with two fingers on a touchscreen, to rotate around the map's center. Scroll to zoom toward the cursor, or pinch to zoom around the midpoint between your fingers. Rotation slows down as you zoom in. When you're comfortable with the controls, press Next to start exploring cells.`)
9
+ return /** @type {LocalizedString} */ (`Welcome to Avoidant. On any map, drag with one finger or the left mouse button to pan. Drag with the right mouse button, hold Shift while dragging with the left mouse button, or drag with two fingers on a touchscreen to rotate around the map's center. Scroll to zoom toward the cursor, or pinch to zoom around the midpoint between your fingers. Rotation slows down as you zoom in. When you're comfortable with the controls, press Next to start exploring cells.`)
10
10
  };
11
11
 
12
12
  const bn_tutorial_intro = /** @type {(inputs: Tutorial_IntroInputs) => LocalizedString} */ () => {
13
- return /** @type {LocalizedString} */ (`Avoidant-এ স্বাগতম। সব ধরনের ম্যাপে এক আঙুল দিয়ে বা মাউসের বাম বা ডান বোতাম চেপে টানলে ম্যাপ সরানো যায়। Shift চেপে টানলে, অথবা টাচস্ক্রিনে দুই আঙুল দিয়ে টানলে, ম্যাপের কেন্দ্র ঘিরে ঘোরানো যায়। কার্সরের অবস্থানের দিকে জুম করতে স্ক্রল করুন। দুই আঙুল কাছাকাছি বা দূরে সরালে আঙুল দুটির মাঝের বিন্দুকে কেন্দ্র করে জুম হবে। জুম করে কাছে গেলে ঘোরানোর গতি কমে। নিয়ন্ত্রণে সাবলীল হলে পরবর্তী চাপুন এবং সেল অনুসন্ধান শুরু করুন।`)
13
+ return /** @type {LocalizedString} */ (`Avoidant-এ স্বাগতম। সব ধরনের ম্যাপে এক আঙুল দিয়ে বা মাউসের বাম বোতাম চেপে টানলে ম্যাপ সরানো যায়। মাউসের ডান বোতাম চেপে টানলে, Shift চেপে ধরে মাউসের বাম বোতাম দিয়ে টানলে, অথবা টাচস্ক্রিনে দুই আঙুল দিয়ে টানলে, ম্যাপের কেন্দ্র ঘিরে ঘোরানো যায়। কার্সরের অবস্থানের দিকে জুম করতে স্ক্রল করুন। দুই আঙুল কাছাকাছি বা দূরে সরালে আঙুল দুটির মাঝের বিন্দুকে কেন্দ্র করে জুম হবে। জুম করে কাছে গেলে ঘোরানোর গতি কমে। নিয়ন্ত্রণে সাবলীল হলে পরবর্তী চাপুন এবং সেল অনুসন্ধান শুরু করুন।`)
14
14
  };
15
15
 
16
16
  /**
17
17
  * | output |
18
18
  * | --- |
19
- * | "Welcome to Avoidant. On any map, drag with one finger or either mouse button to pan. Hold Shift while dragging, or drag with two fingers on a touchscreen, to..." |
19
+ * | "Welcome to Avoidant. On any map, drag with one finger or the left mouse button to pan. Drag with the right mouse button, hold Shift while dragging with the l..." |
20
20
  *
21
21
  * @param {Tutorial_IntroInputs} inputs
22
22
  * @param {{ locale?: "en" | "bn" }} options
@@ -24,6 +24,6 @@ const bn_tutorial_intro = /** @type {(inputs: Tutorial_IntroInputs) => Localized
24
24
  */
25
25
  export const tutorial_intro = /** @type {((inputs?: Tutorial_IntroInputs, options?: { locale?: "en" | "bn" }) => LocalizedString) & import('../runtime.js').MessageMetadata<Tutorial_IntroInputs, { locale?: "en" | "bn" }, {}>} */ ((inputs = {}, options = {}) => {
26
26
  const locale = experimentalStaticLocale ?? options.locale ?? getLocale()
27
- if (locale === "en") return en_tutorial_intro(inputs)
28
- return bn_tutorial_intro(inputs)
27
+ if (locale === "bn") return bn_tutorial_intro(inputs)
28
+ return en_tutorial_intro(inputs)
29
29
  });
@@ -24,6 +24,6 @@ const bn_tutorial_won = /** @type {(inputs: Tutorial_WonInputs) => LocalizedStri
24
24
  */
25
25
  export const tutorial_won = /** @type {((inputs: Tutorial_WonInputs, options?: { locale?: "en" | "bn" }) => LocalizedString) & import('../runtime.js').MessageMetadata<Tutorial_WonInputs, { locale?: "en" | "bn" }, {}>} */ ((inputs, options = {}) => {
26
26
  const locale = experimentalStaticLocale ?? options.locale ?? getLocale()
27
- if (locale === "en") return en_tutorial_won(inputs)
28
- return bn_tutorial_won(inputs)
27
+ if (locale === "bn") return bn_tutorial_won(inputs)
28
+ return en_tutorial_won(inputs)
29
29
  });
@@ -1,3 +1,6 @@
1
+ /**
2
+ * @typedef {"year" | "years" | "quarter" | "quarters" | "month" | "months" | "week" | "weeks" | "day" | "days" | "hour" | "hours" | "minute" | "minutes" | "second" | "seconds"} RelativeTimeFormatUnit
3
+ */
1
4
  /**
2
5
  * @param {import("./runtime.js").Locale} locale
3
6
  * @param {unknown} input
@@ -19,3 +22,13 @@ export function number(locale: import("./runtime.js").Locale, input: unknown, op
19
22
  * @returns {string}
20
23
  */
21
24
  export function datetime(locale: import("./runtime.js").Locale, input: unknown, options?: Intl.DateTimeFormatOptions): string;
25
+ /**
26
+ * @param {import("./runtime.js").Locale} locale
27
+ * @param {unknown} input
28
+ * @param {Intl.RelativeTimeFormatOptions & { unit: RelativeTimeFormatUnit }} options
29
+ * @returns {string}
30
+ */
31
+ export function relativetime(locale: import("./runtime.js").Locale, input: unknown, options: Intl.RelativeTimeFormatOptions & {
32
+ unit: RelativeTimeFormatUnit;
33
+ }): string;
34
+ export type RelativeTimeFormatUnit = "year" | "years" | "quarter" | "quarters" | "month" | "months" | "week" | "weeks" | "day" | "days" | "hour" | "hours" | "minute" | "minutes" | "second" | "seconds";
@@ -1,5 +1,9 @@
1
1
  /* eslint-disable */
2
2
 
3
+ /**
4
+ * @typedef {"year" | "years" | "quarter" | "quarters" | "month" | "months" | "week" | "weeks" | "day" | "days" | "hour" | "hours" | "minute" | "minutes" | "second" | "seconds"} RelativeTimeFormatUnit
5
+ */
6
+
3
7
  /**
4
8
  * @param {import("./runtime.js").Locale} locale
5
9
  * @param {unknown} input
@@ -28,4 +32,15 @@ export function number(locale, input, options) {
28
32
  */
29
33
  export function datetime(locale, input, options) {
30
34
  return new Intl.DateTimeFormat(locale, options).format(new Date(/** @type {string} */ (input)))
35
+ };
36
+
37
+ /**
38
+ * @param {import("./runtime.js").Locale} locale
39
+ * @param {unknown} input
40
+ * @param {Intl.RelativeTimeFormatOptions & { unit: RelativeTimeFormatUnit }} options
41
+ * @returns {string}
42
+ */
43
+ export function relativetime(locale, input, options) {
44
+ const { unit, ...intlOptions } = options;
45
+ return new Intl.RelativeTimeFormat(locale, intlOptions).format(Number(input), unit);
31
46
  };