From ec3177c8345f2aba7dde311fd1d6b551f59d3f4f Mon Sep 17 00:00:00 2001 From: Anders Kaseorg Date: Mon, 11 Nov 2024 18:59:37 -0800 Subject: [PATCH] web: Add explicit extensions to imports. Signed-off-by: Anders Kaseorg --- .eslintrc.js | 2 +- tools/node_lib/dump_fixtures.js | 2 +- tsconfig.json | 1 + web/debug-require-webpack-plugin.ts | 2 +- web/e2e-tests/admin.test.ts | 2 +- web/e2e-tests/compose.test.ts | 2 +- web/e2e-tests/copy-and-paste.test.ts | 2 +- web/e2e-tests/custom-profile.test.ts | 2 +- web/e2e-tests/delete-message.test.ts | 2 +- web/e2e-tests/drafts.test.ts | 2 +- web/e2e-tests/edit.test.ts | 2 +- web/e2e-tests/lib/common.ts | 2 +- web/e2e-tests/mention.test.ts | 2 +- web/e2e-tests/message-basics.test.ts | 2 +- web/e2e-tests/navigation.test.ts | 2 +- web/e2e-tests/realm-creation.test.ts | 2 +- web/e2e-tests/realm-linkifier.test.ts | 2 +- web/e2e-tests/realm-playground.test.ts | 2 +- web/e2e-tests/settings.test.ts | 4 +- web/e2e-tests/stars.test.ts | 2 +- web/e2e-tests/stream_create.test.ts | 2 +- web/e2e-tests/subscribe_toggle.test.ts | 2 +- web/e2e-tests/user-deactivation.test.ts | 2 +- web/e2e-tests/user-status.test.ts | 2 +- web/postcss.config.js | 2 +- web/src/about_zulip.ts | 8 +- web/src/activity.ts | 10 +- web/src/activity_ui.ts | 34 +- web/src/add_group_members_pill.ts | 24 +- web/src/add_stream_options_popover.ts | 6 +- web/src/add_subscribers_pill.ts | 22 +- web/src/admin.js | 36 +-- web/src/alert_words.ts | 6 +- web/src/alert_words_ui.ts | 12 +- web/src/all_messages_data.ts | 4 +- web/src/attachments_ui.ts | 20 +- web/src/audible_notifications.ts | 4 +- web/src/avatar.ts | 14 +- web/src/base_page_params.ts | 2 +- web/src/billing/billing.ts | 4 +- web/src/billing/event_status.ts | 4 +- web/src/billing/helpers.ts | 4 +- web/src/billing/page_params.ts | 2 +- web/src/billing/sponsorship.ts | 4 +- web/src/billing/upgrade.ts | 10 +- web/src/blueslip.ts | 2 +- web/src/bootstrap_typeahead.ts | 4 +- web/src/bot_data.ts | 8 +- web/src/browser_history.ts | 8 +- web/src/buddy_data.ts | 34 +- web/src/buddy_list.ts | 38 +-- web/src/bundles/app.ts | 16 +- web/src/bundles/common.ts | 12 +- web/src/bundles/hello.ts | 2 +- web/src/bundles/portico.ts | 10 +- web/src/channel.ts | 10 +- web/src/click_handlers.js | 70 ++--- web/src/common.ts | 4 +- web/src/components.ts | 4 +- web/src/compose.js | 38 +-- web/src/compose_actions.ts | 46 +-- web/src/compose_banner.ts | 8 +- web/src/compose_call.ts | 2 +- web/src/compose_call_ui.ts | 18 +- web/src/compose_closed_ui.ts | 16 +- web/src/compose_fade.ts | 16 +- web/src/compose_fade_helper.ts | 8 +- web/src/compose_notifications.ts | 24 +- web/src/compose_pm_pill.ts | 14 +- web/src/compose_popovers.ts | 10 +- web/src/compose_recipient.ts | 36 +-- web/src/compose_reply.ts | 36 +-- web/src/compose_send_menu_popover.js | 24 +- web/src/compose_setup.js | 66 ++-- web/src/compose_state.ts | 8 +- web/src/compose_tooltips.ts | 20 +- web/src/compose_ui.ts | 34 +- web/src/compose_validate.ts | 44 +-- web/src/composebox_typeahead.ts | 76 ++--- web/src/condense.ts | 12 +- web/src/confirm_dialog.ts | 6 +- web/src/copied_tooltip.ts | 2 +- web/src/copy_and_paste.ts | 14 +- web/src/custom_profile_fields_ui.ts | 20 +- web/src/demo_organizations_ui.ts | 22 +- web/src/deprecated_feature_notice.ts | 8 +- web/src/desktop_integration.js | 16 +- web/src/desktop_notifications.ts | 4 +- web/src/dialog_widget.ts | 10 +- web/src/direct_message_group_data.ts | 4 +- web/src/drafts.ts | 28 +- web/src/drafts_overlay_ui.js | 22 +- web/src/dropdown_widget.ts | 16 +- web/src/echo.ts | 50 +-- web/src/echo_state.ts | 2 +- web/src/email_pill.ts | 4 +- web/src/emoji.ts | 4 +- web/src/emoji_picker.ts | 36 +-- web/src/emojisets.ts | 4 +- web/src/favicon.ts | 4 +- web/src/feedback_widget.ts | 2 +- web/src/fetch_status.ts | 4 +- web/src/filter.ts | 34 +- web/src/flatpickr.ts | 6 +- web/src/gear_menu.js | 16 +- web/src/gear_menu_util.ts | 4 +- web/src/giphy.js | 12 +- web/src/giphy_state.ts | 2 +- web/src/global.ts | 2 +- web/src/group_permission_settings.ts | 4 +- web/src/group_setting_pill.ts | 24 +- web/src/hash_util.ts | 26 +- web/src/hashchange.js | 66 ++-- web/src/hotkey.js | 124 ++++---- web/src/i18n.ts | 2 +- web/src/inbox_ui.ts | 52 ++-- web/src/inbox_util.ts | 4 +- web/src/info_overlay.ts | 28 +- web/src/information_density.ts | 4 +- web/src/input_pill.ts | 6 +- web/src/integration_url_modal.ts | 16 +- web/src/invite.ts | 46 +-- web/src/invite_stream_picker_pill.ts | 12 +- web/src/lazy_set.ts | 2 +- web/src/left_sidebar_navigation_area.ts | 18 +- .../left_sidebar_navigation_area_popovers.ts | 22 +- web/src/lightbox.ts | 14 +- web/src/linkifiers.ts | 2 +- web/src/list_cursor.ts | 4 +- web/src/list_widget.ts | 4 +- web/src/local_message.ts | 6 +- web/src/localstorage.ts | 2 +- web/src/markdown.ts | 6 +- web/src/markdown_config.ts | 18 +- web/src/message_actions_popover.js | 32 +- web/src/message_edit.ts | 88 +++--- web/src/message_edit_history.ts | 38 +-- web/src/message_events.js | 72 ++--- web/src/message_events_util.ts | 20 +- web/src/message_feed_loading.ts | 2 +- web/src/message_feed_top_notices.ts | 12 +- web/src/message_fetch.ts | 48 +-- web/src/message_flags.ts | 6 +- web/src/message_helper.ts | 24 +- web/src/message_list.ts | 30 +- web/src/message_list_data.ts | 16 +- web/src/message_list_data_cache.ts | 6 +- web/src/message_list_hover.ts | 10 +- web/src/message_list_tooltips.ts | 20 +- web/src/message_list_view.ts | 70 ++--- web/src/message_lists.ts | 10 +- web/src/message_live_update.ts | 6 +- web/src/message_notifications.ts | 30 +- web/src/message_parser.ts | 2 +- web/src/message_scroll.js | 18 +- web/src/message_store.ts | 10 +- web/src/message_util.ts | 20 +- web/src/message_view.ts | 120 +++---- web/src/message_view_header.ts | 28 +- web/src/message_viewport.ts | 12 +- web/src/messages_overlay_ui.ts | 2 +- web/src/modals.ts | 4 +- web/src/muted_users.ts | 8 +- web/src/muted_users_ui.ts | 18 +- web/src/narrow_banner.ts | 22 +- web/src/narrow_history.ts | 10 +- web/src/narrow_state.ts | 18 +- web/src/narrow_title.ts | 22 +- web/src/navbar_alerts.ts | 24 +- web/src/navbar_help_menu.ts | 6 +- web/src/navbar_menus.js | 10 +- web/src/navigate.js | 8 +- web/src/onboarding_steps.ts | 8 +- web/src/overlays.ts | 4 +- web/src/page_params.ts | 2 +- web/src/password_quality.ts | 2 +- web/src/peer_data.ts | 10 +- web/src/people.ts | 34 +- web/src/personal_menu_popover.ts | 20 +- web/src/pill_typeahead.ts | 28 +- web/src/playground_links_popover.ts | 12 +- web/src/pm_conversations.ts | 10 +- web/src/pm_list.ts | 18 +- web/src/pm_list_data.ts | 16 +- web/src/pm_list_dom.ts | 2 +- web/src/poll_modal.ts | 2 +- web/src/poll_widget.ts | 14 +- web/src/popover_menus.ts | 12 +- web/src/popover_menus_data.ts | 46 +-- web/src/portico/desktop-login.ts | 2 +- web/src/portico/email_log.ts | 4 +- web/src/portico/google-analytics.ts | 2 +- web/src/portico/help.ts | 8 +- web/src/portico/integrations.js | 10 +- web/src/portico/integrations_dev_panel.ts | 4 +- web/src/portico/landing-page.ts | 10 +- web/src/portico/portico_modals.ts | 2 +- web/src/portico/signup.ts | 10 +- web/src/portico/tabbed-instructions.ts | 6 +- web/src/postprocess_content.ts | 8 +- web/src/presence.ts | 8 +- web/src/reactions.ts | 26 +- web/src/read_receipts.ts | 16 +- web/src/realm_icon.ts | 8 +- web/src/realm_logo.ts | 12 +- web/src/realm_playground.ts | 6 +- web/src/realm_user_settings_defaults.ts | 2 +- web/src/recent_senders.ts | 8 +- web/src/recent_view_data.ts | 6 +- web/src/recent_view_ui.ts | 72 ++--- web/src/recent_view_util.ts | 2 +- web/src/reload.ts | 24 +- web/src/reload_setup.js | 14 +- web/src/rendered_markdown.ts | 28 +- web/src/resize.ts | 8 +- web/src/resize_handler.ts | 16 +- web/src/rows.ts | 8 +- web/src/saved_snippets.ts | 10 +- web/src/saved_snippets_ui.ts | 20 +- web/src/scheduled_messages.ts | 8 +- web/src/scheduled_messages_feed_ui.ts | 8 +- web/src/scheduled_messages_overlay_ui.ts | 22 +- web/src/scheduled_messages_ui.ts | 16 +- web/src/scroll_bar.ts | 2 +- web/src/scroll_util.ts | 2 +- web/src/search.ts | 22 +- web/src/search_pill.ts | 20 +- web/src/search_suggestion.ts | 28 +- web/src/sent_messages.ts | 2 +- web/src/server_events.js | 26 +- web/src/server_events_dispatch.js | 182 +++++------ web/src/settings.js | 36 +-- web/src/settings_account.ts | 54 ++-- web/src/settings_bots.ts | 38 +-- web/src/settings_components.ts | 48 +-- web/src/settings_config.ts | 16 +- web/src/settings_data.ts | 14 +- web/src/settings_emoji.ts | 30 +- web/src/settings_exports.ts | 32 +- web/src/settings_invites.ts | 28 +- web/src/settings_linkifiers.ts | 22 +- web/src/settings_muted_users.ts | 8 +- web/src/settings_notifications.ts | 42 +-- web/src/settings_org.ts | 60 ++-- web/src/settings_panel_menu.js | 18 +- web/src/settings_playgrounds.ts | 28 +- web/src/settings_preferences.ts | 34 +- web/src/settings_profile_fields.ts | 32 +- web/src/settings_realm_domains.ts | 12 +- .../settings_realm_user_settings_defaults.ts | 24 +- web/src/settings_sections.js | 38 +-- web/src/settings_streams.ts | 26 +- web/src/settings_toggle.js | 6 +- web/src/settings_ui.ts | 8 +- web/src/settings_user_topics.ts | 10 +- web/src/settings_users.ts | 46 +-- web/src/setup.ts | 6 +- web/src/sidebar_ui.ts | 32 +- web/src/spectators.ts | 8 +- web/src/spoilers.ts | 2 +- web/src/starred_messages.ts | 4 +- web/src/starred_messages_ui.ts | 24 +- web/src/state_data.ts | 10 +- web/src/stats/page_params.ts | 2 +- web/src/stats/stats.ts | 6 +- web/src/stream_card_popover.ts | 14 +- web/src/stream_color.ts | 8 +- web/src/stream_color_events.ts | 14 +- web/src/stream_create.ts | 36 +-- web/src/stream_create_subscribers.ts | 16 +- web/src/stream_create_subscribers_data.ts | 6 +- web/src/stream_data.ts | 34 +- web/src/stream_edit.ts | 70 ++--- web/src/stream_edit_subscribers.ts | 40 +-- web/src/stream_edit_toggler.ts | 10 +- web/src/stream_events.js | 52 ++-- web/src/stream_list.ts | 56 ++-- web/src/stream_list_sort.ts | 14 +- web/src/stream_muting.js | 10 +- web/src/stream_pill.ts | 12 +- web/src/stream_popover.js | 50 +-- web/src/stream_settings_api.ts | 8 +- web/src/stream_settings_components.ts | 32 +- web/src/stream_settings_containers.ts | 2 +- web/src/stream_settings_data.ts | 22 +- web/src/stream_settings_ui.js | 66 ++-- web/src/stream_topic_history.ts | 14 +- web/src/stream_topic_history_util.ts | 4 +- web/src/stream_ui_updates.ts | 28 +- web/src/sub_store.ts | 6 +- web/src/submessage.ts | 18 +- web/src/subscriber_api.ts | 6 +- web/src/templates.js | 8 +- web/src/theme.ts | 10 +- web/src/thumbnail.ts | 4 +- web/src/timerender.ts | 10 +- web/src/tippyjs.ts | 16 +- web/src/todo_widget.ts | 12 +- web/src/topic_generator.ts | 14 +- web/src/topic_link_util.ts | 4 +- web/src/topic_list.ts | 16 +- web/src/topic_list_data.ts | 16 +- web/src/topic_popover.js | 24 +- web/src/transmit.js | 18 +- web/src/typeahead_helper.ts | 50 +-- web/src/typing.ts | 20 +- web/src/typing_data.ts | 4 +- web/src/typing_events.ts | 8 +- web/src/ui_init.js | 292 +++++++++--------- web/src/ui_report.ts | 6 +- web/src/ui_util.ts | 6 +- web/src/unread.ts | 30 +- web/src/unread_ops.ts | 40 +-- web/src/unread_ui.ts | 16 +- web/src/upload.ts | 22 +- web/src/upload_widget.ts | 4 +- web/src/user_card_popover.js | 70 ++--- web/src/user_deactivation_ui.ts | 16 +- web/src/user_events.js | 46 +-- web/src/user_group_components.ts | 12 +- web/src/user_group_create.ts | 22 +- web/src/user_group_create_members.ts | 20 +- web/src/user_group_create_members_data.ts | 12 +- web/src/user_group_edit.js | 52 ++-- web/src/user_group_edit_members.ts | 32 +- web/src/user_group_pill.ts | 12 +- web/src/user_group_popover.ts | 26 +- web/src/user_groups.ts | 20 +- web/src/user_pill.ts | 20 +- web/src/user_profile.ts | 86 +++--- web/src/user_search.ts | 6 +- web/src/user_settings.ts | 2 +- web/src/user_sort.ts | 4 +- web/src/user_status.ts | 12 +- web/src/user_status_ui.ts | 16 +- web/src/user_topic_popover.ts | 10 +- web/src/user_topics.ts | 26 +- web/src/user_topics_ui.ts | 28 +- web/src/util.ts | 8 +- web/src/vdom.ts | 2 +- web/src/views_util.ts | 38 +-- web/src/watchdog.ts | 2 +- web/src/widgetize.ts | 10 +- web/src/widgets.js | 8 +- web/src/zcommand.ts | 14 +- web/src/zform.js | 6 +- web/src/zulip_test.ts | 24 +- web/tests/activity.test.js | 12 +- web/tests/alert_words.test.js | 4 +- web/tests/alert_words_ui.test.js | 8 +- web/tests/blueslip_stacktrace.test.js | 4 +- web/tests/bot_data.test.js | 4 +- web/tests/browser_history.test.js | 8 +- web/tests/buddy_data.test.js | 6 +- web/tests/buddy_list.test.js | 10 +- web/tests/channel.test.js | 8 +- web/tests/color_data.test.js | 4 +- web/tests/common.test.js | 6 +- web/tests/components.test.js | 8 +- web/tests/compose.test.js | 10 +- web/tests/compose_actions.test.js | 10 +- web/tests/compose_closed_ui.test.js | 6 +- web/tests/compose_fade.test.js | 4 +- web/tests/compose_pm_pill.test.js | 6 +- web/tests/compose_state.test.js | 6 +- web/tests/compose_ui.test.js | 8 +- web/tests/compose_validate.test.js | 12 +- web/tests/compose_video.test.js | 10 +- web/tests/composebox_typeahead.test.js | 8 +- web/tests/copy_and_paste.test.js | 4 +- web/tests/deprecated_feature_notice.test.js | 4 +- web/tests/dispatch.test.js | 14 +- web/tests/dispatch_subs.test.js | 10 +- web/tests/drafts.test.js | 8 +- web/tests/echo.test.js | 6 +- web/tests/emoji.test.js | 8 +- web/tests/emoji_picker.test.js | 4 +- web/tests/example1.test.js | 8 +- web/tests/example2.test.js | 8 +- web/tests/example3.test.js | 6 +- web/tests/example4.test.js | 6 +- web/tests/example5.test.js | 6 +- web/tests/example6.test.js | 4 +- web/tests/example7.test.js | 8 +- web/tests/example8.test.js | 8 +- web/tests/fenced_code.test.js | 4 +- web/tests/fetch_status.test.js | 4 +- web/tests/filter.test.js | 10 +- web/tests/fold_dict.test.js | 4 +- web/tests/gear_menu_util.test.js | 4 +- web/tests/hash_util.test.js | 6 +- web/tests/hashchange.test.js | 8 +- web/tests/hotkey.test.js | 8 +- web/tests/i18n.test.js | 8 +- web/tests/input_pill.test.js | 6 +- web/tests/internal_url.test.js | 4 +- web/tests/keydown_util.test.js | 6 +- web/tests/lazy_set.test.js | 6 +- .../left_sidebar_navigation_area.test.js | 6 +- web/tests/lib/buddy_list.js | 4 +- web/tests/lib/compose_banner.js | 6 +- web/tests/lib/handlebars.js | 2 +- web/tests/lib/index.js | 30 +- web/tests/lib/markdown_assert.js | 2 +- web/tests/lib/namespace.js | 2 +- web/tests/lib/test.js | 10 +- web/tests/lib/zjquery.js | 4 +- web/tests/lib/zjquery_element.js | 2 +- web/tests/linkifiers.test.js | 6 +- web/tests/list_cursor.test.js | 8 +- web/tests/list_widget.test.js | 8 +- web/tests/markdown.test.js | 10 +- web/tests/markdown_parse.test.js | 4 +- web/tests/message_edit.test.js | 4 +- web/tests/message_events.test.js | 6 +- web/tests/message_flags.test.js | 4 +- web/tests/message_list.test.js | 10 +- web/tests/message_list_data.test.js | 6 +- web/tests/message_list_view.test.js | 6 +- web/tests/message_store.test.js | 6 +- web/tests/message_view.test.js | 10 +- web/tests/muted_users.test.js | 4 +- web/tests/narrow_local.test.js | 4 +- web/tests/narrow_state.test.js | 6 +- web/tests/narrow_unread.test.js | 6 +- web/tests/navbar_alerts.test.js | 6 +- web/tests/notifications.test.js | 8 +- web/tests/password.test.js | 4 +- web/tests/peer_data.test.js | 8 +- web/tests/people.test.js | 10 +- web/tests/people_errors.test.js | 6 +- web/tests/pill_typeahead.test.js | 10 +- web/tests/pm_conversations.test.js | 4 +- web/tests/pm_list.test.js | 6 +- web/tests/pm_list_data.test.js | 6 +- web/tests/poll_widget.test.js | 8 +- web/tests/popover_menus_data.test.js | 8 +- web/tests/postprocess_content.test.js | 4 +- web/tests/presence.test.js | 4 +- web/tests/reactions.test.js | 12 +- web/tests/realm_playground.test.js | 4 +- web/tests/recent_senders.test.js | 4 +- web/tests/recent_view.test.js | 8 +- web/tests/reload.test.js | 4 +- web/tests/reload_state.test.js | 4 +- web/tests/rendered_markdown.test.js | 10 +- web/tests/resolved_topic.test.js | 4 +- web/tests/rtl.test.js | 6 +- web/tests/saved_snippets.test.js | 8 +- web/tests/scheduled_messages.test.js | 4 +- web/tests/scroll_util.test.js | 4 +- web/tests/search.test.js | 6 +- web/tests/search_suggestion.test.js | 6 +- web/tests/server_events.test.js | 8 +- web/tests/settings_bots.test.js | 4 +- web/tests/settings_config.test.js | 4 +- web/tests/settings_data.test.js | 6 +- web/tests/settings_emoji.test.js | 6 +- web/tests/settings_muted_users.test.js | 6 +- web/tests/settings_org.test.js | 8 +- web/tests/settings_profile_fields.test.js | 6 +- web/tests/settings_realm_domains.test.js | 6 +- web/tests/settings_user_topics.test.js | 6 +- web/tests/spoilers.test.js | 6 +- web/tests/starred_messages.test.js | 6 +- .../stream_create_subscribers_data.test.js | 4 +- web/tests/stream_data.test.js | 8 +- web/tests/stream_edit.test.js | 4 +- web/tests/stream_events.test.js | 10 +- web/tests/stream_list.test.js | 8 +- web/tests/stream_list_sort.test.js | 4 +- web/tests/stream_pill.test.js | 4 +- web/tests/stream_search.test.js | 6 +- web/tests/stream_settings_ui.test.js | 6 +- web/tests/stream_topic_history.test.js | 4 +- web/tests/submessage.test.js | 6 +- web/tests/support.test.js | 6 +- web/tests/templates.test.js | 2 +- web/tests/time_zone_util.test.js | 4 +- web/tests/timerender.test.js | 8 +- web/tests/topic_generator.test.js | 4 +- web/tests/topic_link_util.test.js | 4 +- web/tests/topic_list_data.test.js | 4 +- web/tests/transmit.test.js | 6 +- web/tests/typeahead.test.js | 4 +- web/tests/typeahead_helper.test.js | 4 +- web/tests/typing_data.test.js | 4 +- web/tests/typing_events.test.js | 6 +- web/tests/typing_status.test.js | 4 +- web/tests/ui_util.test.js | 6 +- web/tests/unread.test.js | 4 +- web/tests/upload.test.js | 6 +- web/tests/user_events.test.js | 8 +- web/tests/user_group_pill.test.js | 4 +- web/tests/user_groups.test.js | 6 +- web/tests/user_pill.test.js | 6 +- web/tests/user_search.test.js | 6 +- web/tests/user_status.test.js | 4 +- web/tests/user_topics.test.js | 8 +- web/tests/user_topics_ui.test.js | 4 +- web/tests/util.test.js | 4 +- web/tests/vdom.test.js | 6 +- web/tests/watchdog.test.js | 6 +- web/tests/widgetize.test.js | 8 +- web/tests/zblueslip.test.js | 4 +- web/tests/zjquery.test.js | 4 +- web/webpack.config.ts | 6 +- 507 files changed, 3767 insertions(+), 3766 deletions(-) diff --git a/.eslintrc.js b/.eslintrc.js index da70e63123..f3c50392f2 100644 --- a/.eslintrc.js +++ b/.eslintrc.js @@ -51,7 +51,7 @@ module.exports = { ], "formatjs/no-id": "error", "guard-for-in": "error", - "import/extensions": "error", + "import/extensions": ["error", "ignorePackages"], "import/first": "error", "import/newline-after-import": "error", "import/no-cycle": ["error", {ignoreExternal: true}], diff --git a/tools/node_lib/dump_fixtures.js b/tools/node_lib/dump_fixtures.js index 7f33a82e01..f27b3368a5 100644 --- a/tools/node_lib/dump_fixtures.js +++ b/tools/node_lib/dump_fixtures.js @@ -1,5 +1,5 @@ "use strict"; -const events = require("../../web/tests/lib/events"); +const events = require("../../web/tests/lib/events.js"); console.info(JSON.stringify(events.fixtures, null, 4)); diff --git a/tsconfig.json b/tsconfig.json index eabdba7685..83a43995ce 100644 --- a/tsconfig.json +++ b/tsconfig.json @@ -11,6 +11,7 @@ "strict": true, /* Modules */ + "allowImportingTsExtensions": true, "moduleResolution": "node", "paths": { "*": ["./web/src/types/*"], diff --git a/web/debug-require-webpack-plugin.ts b/web/debug-require-webpack-plugin.ts index 5c20c7c450..bea2255d8a 100644 --- a/web/debug-require-webpack-plugin.ts +++ b/web/debug-require-webpack-plugin.ts @@ -64,7 +64,7 @@ export default class DebugRequirePlugin implements WebpackPluginInstance { resolver.resolve( {}, __dirname, - "./debug-require", + "./debug-require.js", {}, (err?: Error | null, result?: string | false) => { resolve(err ? false : result!); diff --git a/web/e2e-tests/admin.test.ts b/web/e2e-tests/admin.test.ts index 4fa9dbc729..aea02a23a2 100644 --- a/web/e2e-tests/admin.test.ts +++ b/web/e2e-tests/admin.test.ts @@ -2,7 +2,7 @@ import assert from "node:assert/strict"; import type {Page} from "puppeteer"; -import * as common from "./lib/common"; +import * as common from "./lib/common.ts"; async function submit_announcements_stream_settings(page: Page): Promise { await page.waitForSelector('#org-notifications .save-button[data-status="unsaved"]', { diff --git a/web/e2e-tests/compose.test.ts b/web/e2e-tests/compose.test.ts index 9c2381046e..13335f405e 100644 --- a/web/e2e-tests/compose.test.ts +++ b/web/e2e-tests/compose.test.ts @@ -2,7 +2,7 @@ import assert from "node:assert/strict"; import type {Page} from "puppeteer"; -import * as common from "./lib/common"; +import * as common from "./lib/common.ts"; async function check_compose_form_empty(page: Page): Promise { await common.check_compose_state(page, { diff --git a/web/e2e-tests/copy-and-paste.test.ts b/web/e2e-tests/copy-and-paste.test.ts index 6e568f85ce..a78d0bf31c 100644 --- a/web/e2e-tests/copy-and-paste.test.ts +++ b/web/e2e-tests/copy-and-paste.test.ts @@ -2,7 +2,7 @@ import assert from "node:assert/strict"; import type {Page} from "puppeteer"; -import * as common from "./lib/common"; +import * as common from "./lib/common.ts"; async function copy_messages( page: Page, diff --git a/web/e2e-tests/custom-profile.test.ts b/web/e2e-tests/custom-profile.test.ts index bec5b7cff0..4a054ea7e5 100644 --- a/web/e2e-tests/custom-profile.test.ts +++ b/web/e2e-tests/custom-profile.test.ts @@ -2,7 +2,7 @@ import assert from "node:assert/strict"; import type {Page} from "puppeteer"; -import * as common from "./lib/common"; +import * as common from "./lib/common.ts"; // This will be the row of the custom profile field we add. const profile_field_row = "#admin_profile_fields_table tr:nth-last-child(1)"; diff --git a/web/e2e-tests/delete-message.test.ts b/web/e2e-tests/delete-message.test.ts index 9a23dba332..fd35410662 100644 --- a/web/e2e-tests/delete-message.test.ts +++ b/web/e2e-tests/delete-message.test.ts @@ -2,7 +2,7 @@ import assert from "node:assert/strict"; import type {Page} from "puppeteer"; -import * as common from "./lib/common"; +import * as common from "./lib/common.ts"; async function click_delete_and_return_last_msg_id(page: Page): Promise { const msg = (await page.$$(".message-list .message_row")).at(-1); diff --git a/web/e2e-tests/drafts.test.ts b/web/e2e-tests/drafts.test.ts index e6159b4e8a..52ea172917 100644 --- a/web/e2e-tests/drafts.test.ts +++ b/web/e2e-tests/drafts.test.ts @@ -2,7 +2,7 @@ import assert from "node:assert/strict"; import type {Page} from "puppeteer"; -import * as common from "./lib/common"; +import * as common from "./lib/common.ts"; async function wait_for_drafts_to_disappear(page: Page): Promise { await page.waitForSelector("#draft_overlay.show", {hidden: true}); diff --git a/web/e2e-tests/edit.test.ts b/web/e2e-tests/edit.test.ts index 23e31897fd..96582c6ca3 100644 --- a/web/e2e-tests/edit.test.ts +++ b/web/e2e-tests/edit.test.ts @@ -2,7 +2,7 @@ import assert from "node:assert/strict"; import type {Page} from "puppeteer"; -import * as common from "./lib/common"; +import * as common from "./lib/common.ts"; async function trigger_edit_last_message(page: Page): Promise { const msg = (await page.$$(".message-list .message_row")).at(-1); diff --git a/web/e2e-tests/lib/common.ts b/web/e2e-tests/lib/common.ts index 79cded3f08..de606c6e2a 100644 --- a/web/e2e-tests/lib/common.ts +++ b/web/e2e-tests/lib/common.ts @@ -9,7 +9,7 @@ import puppeteer from "puppeteer"; import StackFrame from "stackframe"; import StackTraceGPS from "stacktrace-gps"; -import {test_credentials} from "../../../var/puppeteer/test_credentials"; +import {test_credentials} from "../../../var/puppeteer/test_credentials.js"; const root_dir = path.resolve(__dirname, "../../.."); const puppeteer_dir = path.join(root_dir, "var/puppeteer"); diff --git a/web/e2e-tests/mention.test.ts b/web/e2e-tests/mention.test.ts index 02874c1786..1218ab6d0a 100644 --- a/web/e2e-tests/mention.test.ts +++ b/web/e2e-tests/mention.test.ts @@ -2,7 +2,7 @@ import assert from "node:assert/strict"; import type {Page} from "puppeteer"; -import * as common from "./lib/common"; +import * as common from "./lib/common.ts"; async function test_mention(page: Page): Promise { await common.log_in(page); diff --git a/web/e2e-tests/message-basics.test.ts b/web/e2e-tests/message-basics.test.ts index 0102867957..b72d12c103 100644 --- a/web/e2e-tests/message-basics.test.ts +++ b/web/e2e-tests/message-basics.test.ts @@ -2,7 +2,7 @@ import assert from "node:assert/strict"; import type {Page} from "puppeteer"; -import * as common from "./lib/common"; +import * as common from "./lib/common.ts"; async function get_stream_li(page: Page, stream_name: string): Promise { const stream_id = await common.get_stream_id(page, stream_name); diff --git a/web/e2e-tests/navigation.test.ts b/web/e2e-tests/navigation.test.ts index 6bf2401bc4..1cb2a79905 100644 --- a/web/e2e-tests/navigation.test.ts +++ b/web/e2e-tests/navigation.test.ts @@ -2,7 +2,7 @@ import assert from "node:assert/strict"; import type {Page} from "puppeteer"; -import * as common from "./lib/common"; +import * as common from "./lib/common.ts"; async function navigate_using_left_sidebar(page: Page, stream_name: string): Promise { console.log("Visiting #" + stream_name); diff --git a/web/e2e-tests/realm-creation.test.ts b/web/e2e-tests/realm-creation.test.ts index 8022d089b1..42d9cc8711 100644 --- a/web/e2e-tests/realm-creation.test.ts +++ b/web/e2e-tests/realm-creation.test.ts @@ -3,7 +3,7 @@ import assert from "node:assert/strict"; import type {Page} from "puppeteer"; import {z} from "zod"; -import * as common from "./lib/common"; +import * as common from "./lib/common.ts"; const email = "alice@test.example.com"; const organization_name = "Awesome Organization"; diff --git a/web/e2e-tests/realm-linkifier.test.ts b/web/e2e-tests/realm-linkifier.test.ts index 8bbcffcf0c..ce0b533d5b 100644 --- a/web/e2e-tests/realm-linkifier.test.ts +++ b/web/e2e-tests/realm-linkifier.test.ts @@ -2,7 +2,7 @@ import assert from "node:assert/strict"; import type {Page} from "puppeteer"; -import * as common from "./lib/common"; +import * as common from "./lib/common.ts"; async function test_add_linkifier(page: Page): Promise { await page.waitForSelector(".admin-linkifier-form", {visible: true}); diff --git a/web/e2e-tests/realm-playground.test.ts b/web/e2e-tests/realm-playground.test.ts index b430abb9bc..f87759b200 100644 --- a/web/e2e-tests/realm-playground.test.ts +++ b/web/e2e-tests/realm-playground.test.ts @@ -2,7 +2,7 @@ import assert from "node:assert/strict"; import type {Page} from "puppeteer"; -import * as common from "./lib/common"; +import * as common from "./lib/common.ts"; type Playground = { playground_name: string; diff --git a/web/e2e-tests/settings.test.ts b/web/e2e-tests/settings.test.ts index 1f3b08e86c..6db588f7d1 100644 --- a/web/e2e-tests/settings.test.ts +++ b/web/e2e-tests/settings.test.ts @@ -2,9 +2,9 @@ import assert from "node:assert/strict"; import type {Page} from "puppeteer"; -import {test_credentials} from "../../var/puppeteer/test_credentials"; +import {test_credentials} from "../../var/puppeteer/test_credentials.js"; -import * as common from "./lib/common"; +import * as common from "./lib/common.ts"; const OUTGOING_WEBHOOK_BOT_TYPE = "3"; const GENERIC_BOT_TYPE = "1"; diff --git a/web/e2e-tests/stars.test.ts b/web/e2e-tests/stars.test.ts index 76ca5011ea..1e496426ff 100644 --- a/web/e2e-tests/stars.test.ts +++ b/web/e2e-tests/stars.test.ts @@ -2,7 +2,7 @@ import assert from "node:assert/strict"; import type {Page} from "puppeteer"; -import * as common from "./lib/common"; +import * as common from "./lib/common.ts"; const message = "test star"; diff --git a/web/e2e-tests/stream_create.test.ts b/web/e2e-tests/stream_create.test.ts index 20a9fd04d8..790bc98b47 100644 --- a/web/e2e-tests/stream_create.test.ts +++ b/web/e2e-tests/stream_create.test.ts @@ -2,7 +2,7 @@ import assert from "node:assert/strict"; import type {Page} from "puppeteer"; -import * as common from "./lib/common"; +import * as common from "./lib/common.ts"; async function user_row_selector(page: Page, name: string): Promise { const user_id = await common.get_user_id_from_name(page, name); diff --git a/web/e2e-tests/subscribe_toggle.test.ts b/web/e2e-tests/subscribe_toggle.test.ts index 0ee3e44e61..d0c53481d6 100644 --- a/web/e2e-tests/subscribe_toggle.test.ts +++ b/web/e2e-tests/subscribe_toggle.test.ts @@ -1,6 +1,6 @@ import type {ElementHandle, Page} from "puppeteer"; -import * as common from "./lib/common"; +import * as common from "./lib/common.ts"; async function test_subscription_button(page: Page): Promise { const all_stream_selector = "[data-tab-key='all-streams']"; diff --git a/web/e2e-tests/user-deactivation.test.ts b/web/e2e-tests/user-deactivation.test.ts index 8935f9717e..1199f4fd56 100644 --- a/web/e2e-tests/user-deactivation.test.ts +++ b/web/e2e-tests/user-deactivation.test.ts @@ -2,7 +2,7 @@ import assert from "node:assert/strict"; import type {Page} from "puppeteer"; -import * as common from "./lib/common"; +import * as common from "./lib/common.ts"; async function navigate_to_user_list(page: Page): Promise { const menu_selector = "#settings-dropdown"; diff --git a/web/e2e-tests/user-status.test.ts b/web/e2e-tests/user-status.test.ts index fa11dfb7c7..6950abcc6d 100644 --- a/web/e2e-tests/user-status.test.ts +++ b/web/e2e-tests/user-status.test.ts @@ -1,6 +1,6 @@ import type {Page} from "puppeteer"; -import * as common from "./lib/common"; +import * as common from "./lib/common.ts"; async function open_set_user_status_modal(page: Page): Promise { // We are clicking on the menu icon with the help of `waitForFunction` because the list diff --git a/web/postcss.config.js b/web/postcss.config.js index a5b86e05f8..5d3b02ed20 100644 --- a/web/postcss.config.js +++ b/web/postcss.config.js @@ -2,7 +2,7 @@ const path = require("node:path"); -const {media_breakpoints} = require("./src/css_variables"); +const {media_breakpoints} = require("./src/css_variables.js"); const config = ({file}) => ({ plugins: [ diff --git a/web/src/about_zulip.ts b/web/src/about_zulip.ts index 02a0e4065f..e73775779c 100644 --- a/web/src/about_zulip.ts +++ b/web/src/about_zulip.ts @@ -4,10 +4,10 @@ import assert from "minimalistic-assert"; import render_about_zulip from "../templates/about_zulip.hbs"; -import * as browser_history from "./browser_history"; -import {show_copied_confirmation} from "./copied_tooltip"; -import * as overlays from "./overlays"; -import {realm} from "./state_data"; +import * as browser_history from "./browser_history.ts"; +import {show_copied_confirmation} from "./copied_tooltip.ts"; +import * as overlays from "./overlays.ts"; +import {realm} from "./state_data.ts"; export function launch(): void { overlays.open_overlay({ diff --git a/web/src/activity.ts b/web/src/activity.ts index d2f119473b..3583c46d4a 100644 --- a/web/src/activity.ts +++ b/web/src/activity.ts @@ -2,11 +2,11 @@ import $ from "jquery"; import assert from "minimalistic-assert"; import {z} from "zod"; -import * as channel from "./channel"; -import {electron_bridge} from "./electron_bridge"; -import {page_params} from "./page_params"; -import * as presence from "./presence"; -import * as watchdog from "./watchdog"; +import * as channel from "./channel.ts"; +import {electron_bridge} from "./electron_bridge.ts"; +import {page_params} from "./page_params.ts"; +import * as presence from "./presence.ts"; +import * as watchdog from "./watchdog.ts"; const post_presence_response_schema = z.object({ msg: z.string(), diff --git a/web/src/activity_ui.ts b/web/src/activity_ui.ts index 87aa6ce2ac..5d5bc3d219 100644 --- a/web/src/activity_ui.ts +++ b/web/src/activity_ui.ts @@ -4,23 +4,23 @@ import assert from "minimalistic-assert"; import render_empty_list_widget_for_list from "../templates/empty_list_widget_for_list.hbs"; -import * as activity from "./activity"; -import * as blueslip from "./blueslip"; -import * as buddy_data from "./buddy_data"; -import {buddy_list} from "./buddy_list"; -import * as keydown_util from "./keydown_util"; -import {ListCursor} from "./list_cursor"; -import * as people from "./people"; -import * as pm_list from "./pm_list"; -import * as popovers from "./popovers"; -import * as presence from "./presence"; -import type {PresenceInfoFromEvent} from "./presence"; -import * as sidebar_ui from "./sidebar_ui"; -import {realm} from "./state_data"; -import * as ui_util from "./ui_util"; -import type {FullUnreadCountsData} from "./unread"; -import {UserSearch} from "./user_search"; -import * as util from "./util"; +import * as activity from "./activity.ts"; +import * as blueslip from "./blueslip.ts"; +import * as buddy_data from "./buddy_data.ts"; +import {buddy_list} from "./buddy_list.ts"; +import * as keydown_util from "./keydown_util.ts"; +import {ListCursor} from "./list_cursor.ts"; +import * as people from "./people.ts"; +import * as pm_list from "./pm_list.ts"; +import * as popovers from "./popovers.ts"; +import * as presence from "./presence.ts"; +import type {PresenceInfoFromEvent} from "./presence.ts"; +import * as sidebar_ui from "./sidebar_ui.ts"; +import {realm} from "./state_data.ts"; +import * as ui_util from "./ui_util.ts"; +import type {FullUnreadCountsData} from "./unread.ts"; +import {UserSearch} from "./user_search.ts"; +import * as util from "./util.ts"; export let user_cursor: ListCursor | undefined; export let user_filter: UserSearch | undefined; diff --git a/web/src/add_group_members_pill.ts b/web/src/add_group_members_pill.ts index bb85c00e20..43205e6ede 100644 --- a/web/src/add_group_members_pill.ts +++ b/web/src/add_group_members_pill.ts @@ -1,17 +1,17 @@ import assert from "minimalistic-assert"; -import * as add_subscribers_pill from "./add_subscribers_pill"; -import * as input_pill from "./input_pill"; -import * as keydown_util from "./keydown_util"; -import type {User} from "./people"; -import * as stream_pill from "./stream_pill"; -import type {CombinedPill, CombinedPillContainer} from "./typeahead_helper"; -import * as user_group_components from "./user_group_components"; -import * as user_group_create_members_data from "./user_group_create_members_data"; -import * as user_group_pill from "./user_group_pill"; -import * as user_groups from "./user_groups"; -import type {UserGroup} from "./user_groups"; -import * as user_pill from "./user_pill"; +import * as add_subscribers_pill from "./add_subscribers_pill.ts"; +import * as input_pill from "./input_pill.ts"; +import * as keydown_util from "./keydown_util.ts"; +import type {User} from "./people.ts"; +import * as stream_pill from "./stream_pill.ts"; +import type {CombinedPill, CombinedPillContainer} from "./typeahead_helper.ts"; +import * as user_group_components from "./user_group_components.ts"; +import * as user_group_create_members_data from "./user_group_create_members_data.ts"; +import * as user_group_pill from "./user_group_pill.ts"; +import * as user_groups from "./user_groups.ts"; +import type {UserGroup} from "./user_groups.ts"; +import * as user_pill from "./user_pill.ts"; function get_pill_user_ids(pill_widget: CombinedPillContainer): number[] { const user_ids = user_pill.get_user_ids(pill_widget); diff --git a/web/src/add_stream_options_popover.ts b/web/src/add_stream_options_popover.ts index cb5d4e5ea7..8c76354fb6 100644 --- a/web/src/add_stream_options_popover.ts +++ b/web/src/add_stream_options_popover.ts @@ -4,9 +4,9 @@ import type * as tippy from "tippy.js"; import render_left_sidebar_stream_setting_popover from "../templates/popovers/left_sidebar/left_sidebar_stream_setting_popover.hbs"; -import * as popover_menus from "./popover_menus"; -import * as settings_data from "./settings_data"; -import {parse_html} from "./ui_util"; +import * as popover_menus from "./popover_menus.ts"; +import * as settings_data from "./settings_data.ts"; +import {parse_html} from "./ui_util.ts"; export function initialize(): void { popover_menus.register_popover_menu("#streams_inline_icon", { diff --git a/web/src/add_subscribers_pill.ts b/web/src/add_subscribers_pill.ts index 46743ab8c6..c4c3adda55 100644 --- a/web/src/add_subscribers_pill.ts +++ b/web/src/add_subscribers_pill.ts @@ -2,17 +2,17 @@ import assert from "minimalistic-assert"; import render_input_pill from "../templates/input_pill.hbs"; -import * as blueslip from "./blueslip"; -import * as input_pill from "./input_pill"; -import * as keydown_util from "./keydown_util"; -import type {User} from "./people"; -import * as pill_typeahead from "./pill_typeahead"; -import * as stream_pill from "./stream_pill"; -import type {CombinedPill, CombinedPillContainer} from "./typeahead_helper"; -import * as user_group_pill from "./user_group_pill"; -import * as user_groups from "./user_groups"; -import type {UserGroup} from "./user_groups"; -import * as user_pill from "./user_pill"; +import * as blueslip from "./blueslip.ts"; +import * as input_pill from "./input_pill.ts"; +import * as keydown_util from "./keydown_util.ts"; +import type {User} from "./people.ts"; +import * as pill_typeahead from "./pill_typeahead.ts"; +import * as stream_pill from "./stream_pill.ts"; +import type {CombinedPill, CombinedPillContainer} from "./typeahead_helper.ts"; +import * as user_group_pill from "./user_group_pill.ts"; +import * as user_groups from "./user_groups.ts"; +import type {UserGroup} from "./user_groups.ts"; +import * as user_pill from "./user_pill.ts"; export function create_item_from_text( text: string, diff --git a/web/src/admin.js b/web/src/admin.js index 3f74031b5c..4d6b45db70 100644 --- a/web/src/admin.js +++ b/web/src/admin.js @@ -4,24 +4,24 @@ import * as tippy from "tippy.js"; import render_admin_tab from "../templates/settings/admin_tab.hbs"; import render_settings_organization_settings_tip from "../templates/settings/organization_settings_tip.hbs"; -import * as bot_data from "./bot_data"; -import * as demo_organizations_ui from "./demo_organizations_ui"; -import {$t, get_language_name, language_list} from "./i18n"; -import {page_params} from "./page_params"; -import * as people from "./people"; -import {realm_user_settings_defaults} from "./realm_user_settings_defaults"; -import * as settings from "./settings"; -import * as settings_bots from "./settings_bots"; -import * as settings_components from "./settings_components"; -import * as settings_config from "./settings_config"; -import * as settings_data from "./settings_data"; -import * as settings_invites from "./settings_invites"; -import * as settings_org from "./settings_org"; -import * as settings_panel_menu from "./settings_panel_menu"; -import * as settings_sections from "./settings_sections"; -import * as settings_toggle from "./settings_toggle"; -import * as settings_users from "./settings_users"; -import {current_user, realm} from "./state_data"; +import * as bot_data from "./bot_data.ts"; +import * as demo_organizations_ui from "./demo_organizations_ui.ts"; +import {$t, get_language_name, language_list} from "./i18n.ts"; +import {page_params} from "./page_params.ts"; +import * as people from "./people.ts"; +import {realm_user_settings_defaults} from "./realm_user_settings_defaults.ts"; +import * as settings from "./settings.js"; +import * as settings_bots from "./settings_bots.ts"; +import * as settings_components from "./settings_components.ts"; +import * as settings_config from "./settings_config.ts"; +import * as settings_data from "./settings_data.ts"; +import * as settings_invites from "./settings_invites.ts"; +import * as settings_org from "./settings_org.ts"; +import * as settings_panel_menu from "./settings_panel_menu.js"; +import * as settings_sections from "./settings_sections.js"; +import * as settings_toggle from "./settings_toggle.js"; +import * as settings_users from "./settings_users.ts"; +import {current_user, realm} from "./state_data.ts"; const admin_settings_label = { // Organization profile diff --git a/web/src/alert_words.ts b/web/src/alert_words.ts index 3fe35f12b1..3dac8df4f0 100644 --- a/web/src/alert_words.ts +++ b/web/src/alert_words.ts @@ -1,8 +1,8 @@ import _ from "lodash"; -import type {Message} from "./message_store"; -import * as people from "./people"; -import type {StateData} from "./state_data"; +import type {Message} from "./message_store.ts"; +import * as people from "./people.ts"; +import type {StateData} from "./state_data.ts"; // For simplicity, we use a list for our internal // data, since that matches what the server sends us. diff --git a/web/src/alert_words_ui.ts b/web/src/alert_words_ui.ts index 70b268aebc..39b15da6b4 100644 --- a/web/src/alert_words_ui.ts +++ b/web/src/alert_words_ui.ts @@ -3,12 +3,12 @@ import $ from "jquery"; import render_add_alert_word from "../templates/settings/add_alert_word.hbs"; import render_alert_word_settings_item from "../templates/settings/alert_word_settings_item.hbs"; -import * as alert_words from "./alert_words"; -import * as channel from "./channel"; -import * as dialog_widget from "./dialog_widget"; -import {$t, $t_html} from "./i18n"; -import * as ListWidget from "./list_widget"; -import * as ui_report from "./ui_report"; +import * as alert_words from "./alert_words.ts"; +import * as channel from "./channel.ts"; +import * as dialog_widget from "./dialog_widget.ts"; +import {$t, $t_html} from "./i18n.ts"; +import * as ListWidget from "./list_widget.ts"; +import * as ui_report from "./ui_report.ts"; export let loaded = false; diff --git a/web/src/all_messages_data.ts b/web/src/all_messages_data.ts index d63641c466..e21164c7e6 100644 --- a/web/src/all_messages_data.ts +++ b/web/src/all_messages_data.ts @@ -1,5 +1,5 @@ -import {Filter} from "./filter"; -import {MessageListData} from "./message_list_data"; +import {Filter} from "./filter.ts"; +import {MessageListData} from "./message_list_data.ts"; export let all_messages_data = new MessageListData({ excludes_muted_topics: false, diff --git a/web/src/attachments_ui.ts b/web/src/attachments_ui.ts index 7d0ef31877..588215a50a 100644 --- a/web/src/attachments_ui.ts +++ b/web/src/attachments_ui.ts @@ -6,16 +6,16 @@ import render_confirm_delete_detached_attachments_modal from "../templates/confi import render_settings_upload_space_stats from "../templates/settings/upload_space_stats.hbs"; import render_uploaded_files_list from "../templates/settings/uploaded_files_list.hbs"; -import {attachment_api_response_schema} from "./attachments"; -import * as channel from "./channel"; -import * as dialog_widget from "./dialog_widget"; -import {$t, $t_html} from "./i18n"; -import * as ListWidget from "./list_widget"; -import * as loading from "./loading"; -import * as scroll_util from "./scroll_util"; -import {realm} from "./state_data"; -import * as timerender from "./timerender"; -import * as ui_report from "./ui_report"; +import {attachment_api_response_schema} from "./attachments.ts"; +import * as channel from "./channel.ts"; +import * as dialog_widget from "./dialog_widget.ts"; +import {$t, $t_html} from "./i18n.ts"; +import * as ListWidget from "./list_widget.ts"; +import * as loading from "./loading.ts"; +import * as scroll_util from "./scroll_util.ts"; +import {realm} from "./state_data.ts"; +import * as timerender from "./timerender.ts"; +import * as ui_report from "./ui_report.ts"; type ServerAttachment = z.infer["attachments"][number]; diff --git a/web/src/audible_notifications.ts b/web/src/audible_notifications.ts index ee8ec54f6d..a1fb5eb80b 100644 --- a/web/src/audible_notifications.ts +++ b/web/src/audible_notifications.ts @@ -1,7 +1,7 @@ import $ from "jquery"; -import {user_settings} from "./user_settings"; -import * as util from "./util"; +import {user_settings} from "./user_settings.ts"; +import * as util from "./util.ts"; export function initialize(): void { update_notification_sound_source($("audio#user-notification-sound-audio"), user_settings); diff --git a/web/src/avatar.ts b/web/src/avatar.ts index 255ffd88db..34ffb09931 100644 --- a/web/src/avatar.ts +++ b/web/src/avatar.ts @@ -2,13 +2,13 @@ import $ from "jquery"; import render_confirm_delete_user_avatar from "../templates/confirm_dialog/confirm_delete_user_avatar.hbs"; -import * as channel from "./channel"; -import * as confirm_dialog from "./confirm_dialog"; -import {$t_html} from "./i18n"; -import * as settings_data from "./settings_data"; -import {current_user, realm} from "./state_data"; -import * as upload_widget from "./upload_widget"; -import type {UploadFunction, UploadWidget} from "./upload_widget"; +import * as channel from "./channel.ts"; +import * as confirm_dialog from "./confirm_dialog.ts"; +import {$t_html} from "./i18n.ts"; +import * as settings_data from "./settings_data.ts"; +import {current_user, realm} from "./state_data.ts"; +import * as upload_widget from "./upload_widget.ts"; +import type {UploadFunction, UploadWidget} from "./upload_widget.ts"; export function build_bot_create_widget(): UploadWidget { // We have to do strange gyrations with the file input to clear it, diff --git a/web/src/base_page_params.ts b/web/src/base_page_params.ts index ac05bc96d5..2cdfbc12a2 100644 --- a/web/src/base_page_params.ts +++ b/web/src/base_page_params.ts @@ -1,6 +1,6 @@ import {z} from "zod"; -import {narrow_term_schema, state_data_schema} from "./state_data"; +import {narrow_term_schema, state_data_schema} from "./state_data.ts"; const t1 = performance.now(); diff --git a/web/src/billing/billing.ts b/web/src/billing/billing.ts index 41f6c35fa7..432cc50d83 100644 --- a/web/src/billing/billing.ts +++ b/web/src/billing/billing.ts @@ -1,9 +1,9 @@ import $ from "jquery"; import {z} from "zod"; -import * as portico_modals from "../portico/portico_modals"; +import * as portico_modals from "../portico/portico_modals.ts"; -import * as helpers from "./helpers"; +import * as helpers from "./helpers.ts"; const billing_frequency_schema = z.enum(["Monthly", "Annual"]); const billing_base_url = $("#billing-page").attr("data-billing-base-url")!; diff --git a/web/src/billing/event_status.ts b/web/src/billing/event_status.ts index f463b6168e..0396a812d4 100644 --- a/web/src/billing/event_status.ts +++ b/web/src/billing/event_status.ts @@ -1,9 +1,9 @@ import $ from "jquery"; import {z} from "zod"; -import * as loading from "../loading"; +import * as loading from "../loading.ts"; -import * as helpers from "./helpers"; +import * as helpers from "./helpers.ts"; const billing_base_url = $("#data").attr("data-billing-base-url")!; diff --git a/web/src/billing/helpers.ts b/web/src/billing/helpers.ts index c3f252be45..ec482a7b77 100644 --- a/web/src/billing/helpers.ts +++ b/web/src/billing/helpers.ts @@ -1,8 +1,8 @@ import $ from "jquery"; import {z} from "zod"; -import * as loading from "../loading"; -import * as util from "../util"; +import * as loading from "../loading.ts"; +import * as util from "../util.ts"; export type FormDataObject = Record; diff --git a/web/src/billing/page_params.ts b/web/src/billing/page_params.ts index 5a3734db3c..8996b08d3f 100644 --- a/web/src/billing/page_params.ts +++ b/web/src/billing/page_params.ts @@ -1,6 +1,6 @@ import assert from "minimalistic-assert"; -import {page_params as base_page_params} from "../base_page_params"; +import {page_params as base_page_params} from "../base_page_params.ts"; assert(base_page_params.page_type === "upgrade"); diff --git a/web/src/billing/sponsorship.ts b/web/src/billing/sponsorship.ts index 8dcfeb9fe6..16f4c3f459 100644 --- a/web/src/billing/sponsorship.ts +++ b/web/src/billing/sponsorship.ts @@ -2,9 +2,9 @@ import $ from "jquery"; import assert from "minimalistic-assert"; import {z} from "zod"; -import {the} from "../util"; +import {the} from "../util.ts"; -import * as helpers from "./helpers"; +import * as helpers from "./helpers.ts"; const is_remotely_hosted = $("#sponsorship-form").attr("data-is-remotely-hosted") === "True"; diff --git a/web/src/billing/upgrade.ts b/web/src/billing/upgrade.ts index 70a758974d..8d891139fb 100644 --- a/web/src/billing/upgrade.ts +++ b/web/src/billing/upgrade.ts @@ -1,12 +1,12 @@ import $ from "jquery"; import {z} from "zod"; -import {localstorage} from "../localstorage"; -import * as portico_modals from "../portico/portico_modals"; +import {localstorage} from "../localstorage.ts"; +import * as portico_modals from "../portico/portico_modals.ts"; -import * as helpers from "./helpers"; -import type {Prices} from "./helpers"; -import {page_params} from "./page_params"; +import * as helpers from "./helpers.ts"; +import type {Prices} from "./helpers.ts"; +import {page_params} from "./page_params.ts"; const prices: Prices = { annual: page_params.annual_price, diff --git a/web/src/blueslip.ts b/web/src/blueslip.ts index dc77d10787..7749615c5d 100644 --- a/web/src/blueslip.ts +++ b/web/src/blueslip.ts @@ -9,7 +9,7 @@ import * as Sentry from "@sentry/browser"; import $ from "jquery"; -import {BlueslipError, display_stacktrace} from "./blueslip_stacktrace"; +import {BlueslipError, display_stacktrace} from "./blueslip_stacktrace.ts"; if (Error.stackTraceLimit !== undefined) { Error.stackTraceLimit = 100000; diff --git a/web/src/bootstrap_typeahead.ts b/web/src/bootstrap_typeahead.ts index e99ae6b8ba..f0e508523f 100644 --- a/web/src/bootstrap_typeahead.ts +++ b/web/src/bootstrap_typeahead.ts @@ -164,8 +164,8 @@ import {insertTextIntoField} from "text-field-edit"; import getCaretCoordinates from "textarea-caret"; import * as tippy from "tippy.js"; -import * as scroll_util from "./scroll_util"; -import {get_string_diff, the} from "./util"; +import * as scroll_util from "./scroll_util.ts"; +import {get_string_diff, the} from "./util.ts"; export function defaultSorter(items: string[], query: string): string[] { const beginswith = []; diff --git a/web/src/bot_data.ts b/web/src/bot_data.ts index 008b2f078c..07aadc2da6 100644 --- a/web/src/bot_data.ts +++ b/web/src/bot_data.ts @@ -1,9 +1,9 @@ import type {z} from "zod"; -import type {services_schema} from "./bot_types"; -import {server_add_bot_schema, server_update_bot_schema} from "./bot_types"; -import * as people from "./people"; -import type {StateData} from "./state_data"; +import type {services_schema} from "./bot_types.ts"; +import {server_add_bot_schema, server_update_bot_schema} from "./bot_types.ts"; +import * as people from "./people.ts"; +import type {StateData} from "./state_data.ts"; export type ServerUpdateBotData = z.infer; export type ServerAddBotData = z.infer; diff --git a/web/src/browser_history.ts b/web/src/browser_history.ts index 6ae141957e..f169ad65b1 100644 --- a/web/src/browser_history.ts +++ b/web/src/browser_history.ts @@ -1,10 +1,10 @@ // TODO: Rewrite this module to use window.history.pushState. import {z} from "zod"; -import * as blueslip from "./blueslip"; -import * as hash_parser from "./hash_parser"; -import * as ui_util from "./ui_util"; -import {user_settings} from "./user_settings"; +import * as blueslip from "./blueslip.ts"; +import * as hash_parser from "./hash_parser.ts"; +import * as ui_util from "./ui_util.ts"; +import {user_settings} from "./user_settings.ts"; export const state: { is_internal_change: boolean; diff --git a/web/src/buddy_data.ts b/web/src/buddy_data.ts index 637f293651..57eaff0daa 100644 --- a/web/src/buddy_data.ts +++ b/web/src/buddy_data.ts @@ -1,22 +1,22 @@ import assert from "minimalistic-assert"; -import * as hash_util from "./hash_util"; -import {$t} from "./i18n"; -import * as message_lists from "./message_lists"; -import * as muted_users from "./muted_users"; -import * as narrow_state from "./narrow_state"; -import {page_params} from "./page_params"; -import * as peer_data from "./peer_data"; -import * as people from "./people"; -import * as presence from "./presence"; -import {realm} from "./state_data"; -import * as stream_data from "./stream_data"; -import type {StreamSubscription} from "./sub_store"; -import * as timerender from "./timerender"; -import * as unread from "./unread"; -import {user_settings} from "./user_settings"; -import * as user_status from "./user_status"; -import * as util from "./util"; +import * as hash_util from "./hash_util.ts"; +import {$t} from "./i18n.ts"; +import * as message_lists from "./message_lists.ts"; +import * as muted_users from "./muted_users.ts"; +import * as narrow_state from "./narrow_state.ts"; +import {page_params} from "./page_params.ts"; +import * as peer_data from "./peer_data.ts"; +import * as people from "./people.ts"; +import * as presence from "./presence.ts"; +import {realm} from "./state_data.ts"; +import * as stream_data from "./stream_data.ts"; +import type {StreamSubscription} from "./sub_store.ts"; +import * as timerender from "./timerender.ts"; +import * as unread from "./unread.ts"; +import {user_settings} from "./user_settings.ts"; +import * as user_status from "./user_status.ts"; +import * as util from "./util.ts"; /* diff --git a/web/src/buddy_list.ts b/web/src/buddy_list.ts index 8ce01cbce8..81eec3e6d2 100644 --- a/web/src/buddy_list.ts +++ b/web/src/buddy_list.ts @@ -9,25 +9,25 @@ import render_empty_list_widget_for_list from "../templates/empty_list_widget_fo import render_presence_row from "../templates/presence_row.hbs"; import render_presence_rows from "../templates/presence_rows.hbs"; -import * as blueslip from "./blueslip"; -import * as buddy_data from "./buddy_data"; -import type {BuddyUserInfo} from "./buddy_data"; -import {media_breakpoints_num} from "./css_variables"; -import type {Filter} from "./filter"; -import * as hash_util from "./hash_util"; -import {$t} from "./i18n"; -import * as message_viewport from "./message_viewport"; -import * as narrow_state from "./narrow_state"; -import * as padded_widget from "./padded_widget"; -import * as peer_data from "./peer_data"; -import * as people from "./people"; -import * as scroll_util from "./scroll_util"; -import {current_user} from "./state_data"; -import * as stream_data from "./stream_data"; -import type {StreamSubscription} from "./sub_store"; -import {INTERACTIVE_HOVER_DELAY} from "./tippyjs"; -import {user_settings} from "./user_settings"; -import * as util from "./util"; +import * as blueslip from "./blueslip.ts"; +import * as buddy_data from "./buddy_data.ts"; +import type {BuddyUserInfo} from "./buddy_data.ts"; +import {media_breakpoints_num} from "./css_variables.js"; +import type {Filter} from "./filter.ts"; +import * as hash_util from "./hash_util.ts"; +import {$t} from "./i18n.ts"; +import * as message_viewport from "./message_viewport.ts"; +import * as narrow_state from "./narrow_state.ts"; +import * as padded_widget from "./padded_widget.ts"; +import * as peer_data from "./peer_data.ts"; +import * as people from "./people.ts"; +import * as scroll_util from "./scroll_util.ts"; +import {current_user} from "./state_data.ts"; +import * as stream_data from "./stream_data.ts"; +import type {StreamSubscription} from "./sub_store.ts"; +import {INTERACTIVE_HOVER_DELAY} from "./tippyjs.ts"; +import {user_settings} from "./user_settings.ts"; +import * as util from "./util.ts"; function get_formatted_sub_count(sub_count: number): string { if (sub_count < 1000) { diff --git a/web/src/bundles/app.ts b/web/src/bundles/app.ts index 804afc6892..fdcf83cf20 100644 --- a/web/src/bundles/app.ts +++ b/web/src/bundles/app.ts @@ -1,17 +1,17 @@ -import "./common"; +import "./common.ts"; // Import third party jQuery plugins -import "../bootstrap_typeahead"; +import "../bootstrap_typeahead.ts"; import "jquery-caret-plugin/dist/jquery.caret"; -import "../../third/jquery-idle/jquery.idle"; +import "../../third/jquery-idle/jquery.idle.js"; import "spectrum-colorpicker"; import "jquery-validation"; // Import app JS -import "../setup"; -import "../reload"; -import "../templates"; -import "../zulip_test"; +import "../setup.ts"; +import "../reload.ts"; +import "../templates.js"; +import "../zulip_test.ts"; // Import styles import "tippy.js/dist/tippy.css"; @@ -60,4 +60,4 @@ import "../../styles/print.css"; import "../../styles/inbox.css"; // This should be last. -import "../ui_init"; +import "../ui_init.js"; diff --git a/web/src/bundles/common.ts b/web/src/bundles/common.ts index a808f9450b..76c10355d9 100644 --- a/web/src/bundles/common.ts +++ b/web/src/bundles/common.ts @@ -1,12 +1,12 @@ -import "../sentry"; -import "../../debug-require"; -import "../alert_popup"; -import "../csrf"; -import "../blueslip"; +import "../sentry.ts"; +import "../../debug-require.js"; +import "../alert_popup.ts"; +import "../csrf.ts"; +import "../blueslip.ts"; import "../../third/bootstrap/css/bootstrap-btn.css"; import "simplebar/dist/simplebar.css"; import "font-awesome/css/font-awesome.css"; -import "../../images/icons/zulip-icons.font"; +import "../../images/icons/zulip-icons.font.js"; import "source-sans/source-sans-3VF.css"; import "source-code-pro/source-code-pro.css"; import "@fontsource-variable/open-sans"; diff --git a/web/src/bundles/hello.ts b/web/src/bundles/hello.ts index 75bd17a2a2..91c7862d40 100644 --- a/web/src/bundles/hello.ts +++ b/web/src/bundles/hello.ts @@ -4,4 +4,4 @@ import "source-sans/source-sans-3VF.css"; import "source-code-pro/source-code-pro.css"; import "@fontsource-variable/open-sans"; -import "../portico/google-analytics"; +import "../portico/google-analytics.ts"; diff --git a/web/src/bundles/portico.ts b/web/src/bundles/portico.ts index 5635188842..3b94d55f9b 100644 --- a/web/src/bundles/portico.ts +++ b/web/src/bundles/portico.ts @@ -1,8 +1,8 @@ -import "./common"; -import "../portico/header"; -import "../portico/google-analytics"; -import "../portico/portico_modals"; -import "../portico/tippyjs"; +import "./common.ts"; +import "../portico/header.ts"; +import "../portico/google-analytics.ts"; +import "../portico/portico_modals.ts"; +import "../portico/tippyjs.ts"; import "../../third/bootstrap/css/bootstrap.portico.css"; import "../../styles/portico/portico_styles.css"; import "tippy.js/dist/tippy.css"; diff --git a/web/src/channel.ts b/web/src/channel.ts index 00acc069f1..eb61adbbc9 100644 --- a/web/src/channel.ts +++ b/web/src/channel.ts @@ -3,11 +3,11 @@ import $ from "jquery"; import _ from "lodash"; import {z} from "zod"; -import {page_params} from "./base_page_params"; -import * as blueslip from "./blueslip"; -import * as reload_state from "./reload_state"; -import {normalize_path, shouldCreateSpanForRequest} from "./sentry"; -import * as spectators from "./spectators"; +import {page_params} from "./base_page_params.ts"; +import * as blueslip from "./blueslip.ts"; +import * as reload_state from "./reload_state.ts"; +import {normalize_path, shouldCreateSpanForRequest} from "./sentry.ts"; +import * as spectators from "./spectators.ts"; // We omit `success` handler from original `AjaxSettings` type because it types // the `data` parameter as `any` type and we want to avoid that. diff --git a/web/src/click_handlers.js b/web/src/click_handlers.js index 5ceb2472e5..3c2251049a 100644 --- a/web/src/click_handlers.js +++ b/web/src/click_handlers.js @@ -6,41 +6,41 @@ import * as tippy from "tippy.js"; import render_buddy_list_tooltip_content from "../templates/buddy_list_tooltip_content.hbs"; -import * as activity_ui from "./activity_ui"; -import * as browser_history from "./browser_history"; -import * as buddy_data from "./buddy_data"; -import * as compose_actions from "./compose_actions"; -import * as compose_reply from "./compose_reply"; -import * as compose_state from "./compose_state"; -import {media_breakpoints_num} from "./css_variables"; -import * as emoji_picker from "./emoji_picker"; -import * as hash_util from "./hash_util"; -import * as hashchange from "./hashchange"; -import * as message_edit from "./message_edit"; -import * as message_lists from "./message_lists"; -import * as message_store from "./message_store"; -import * as message_view from "./message_view"; -import * as narrow_state from "./narrow_state"; -import * as navigate from "./navigate"; -import {page_params} from "./page_params"; -import * as pm_list from "./pm_list"; -import * as popover_menus from "./popover_menus"; -import * as reactions from "./reactions"; -import * as recent_view_ui from "./recent_view_ui"; -import * as rows from "./rows"; -import * as server_events from "./server_events"; -import * as settings_panel_menu from "./settings_panel_menu"; -import * as settings_preferences from "./settings_preferences"; -import * as settings_toggle from "./settings_toggle"; -import * as sidebar_ui from "./sidebar_ui"; -import * as spectators from "./spectators"; -import * as starred_messages_ui from "./starred_messages_ui"; -import * as stream_list from "./stream_list"; -import * as stream_popover from "./stream_popover"; -import * as topic_list from "./topic_list"; -import * as ui_util from "./ui_util"; -import {parse_html} from "./ui_util"; -import * as util from "./util"; +import * as activity_ui from "./activity_ui.ts"; +import * as browser_history from "./browser_history.ts"; +import * as buddy_data from "./buddy_data.ts"; +import * as compose_actions from "./compose_actions.ts"; +import * as compose_reply from "./compose_reply.ts"; +import * as compose_state from "./compose_state.ts"; +import {media_breakpoints_num} from "./css_variables.js"; +import * as emoji_picker from "./emoji_picker.ts"; +import * as hash_util from "./hash_util.ts"; +import * as hashchange from "./hashchange.js"; +import * as message_edit from "./message_edit.ts"; +import * as message_lists from "./message_lists.ts"; +import * as message_store from "./message_store.ts"; +import * as message_view from "./message_view.ts"; +import * as narrow_state from "./narrow_state.ts"; +import * as navigate from "./navigate.js"; +import {page_params} from "./page_params.ts"; +import * as pm_list from "./pm_list.ts"; +import * as popover_menus from "./popover_menus.ts"; +import * as reactions from "./reactions.ts"; +import * as recent_view_ui from "./recent_view_ui.ts"; +import * as rows from "./rows.ts"; +import * as server_events from "./server_events.js"; +import * as settings_panel_menu from "./settings_panel_menu.js"; +import * as settings_preferences from "./settings_preferences.ts"; +import * as settings_toggle from "./settings_toggle.js"; +import * as sidebar_ui from "./sidebar_ui.ts"; +import * as spectators from "./spectators.ts"; +import * as starred_messages_ui from "./starred_messages_ui.ts"; +import * as stream_list from "./stream_list.ts"; +import * as stream_popover from "./stream_popover.js"; +import * as topic_list from "./topic_list.ts"; +import * as ui_util from "./ui_util.ts"; +import {parse_html} from "./ui_util.ts"; +import * as util from "./util.ts"; export function initialize() { // MESSAGE CLICKING diff --git a/web/src/common.ts b/web/src/common.ts index d9b5018a76..491f35cc18 100644 --- a/web/src/common.ts +++ b/web/src/common.ts @@ -1,8 +1,8 @@ import $ from "jquery"; import * as tippy from "tippy.js"; -import {$t} from "./i18n"; -import * as util from "./util"; +import {$t} from "./i18n.ts"; +import * as util from "./util.ts"; export const status_classes = "alert-error alert-success alert-info alert-warning alert-loading"; diff --git a/web/src/components.ts b/web/src/components.ts index 0d22a0a277..677f539a96 100644 --- a/web/src/components.ts +++ b/web/src/components.ts @@ -1,7 +1,7 @@ import $ from "jquery"; -import * as blueslip from "./blueslip"; -import * as keydown_util from "./keydown_util"; +import * as blueslip from "./blueslip.ts"; +import * as keydown_util from "./keydown_util.ts"; /* USAGE: Toggle x = components.toggle({ diff --git a/web/src/compose.js b/web/src/compose.js index d78e143a31..e6f236f2ff 100644 --- a/web/src/compose.js +++ b/web/src/compose.js @@ -6,25 +6,25 @@ import $ from "jquery"; import render_success_message_scheduled_banner from "../templates/compose_banner/success_message_scheduled_banner.hbs"; import render_wildcard_mention_not_allowed_error from "../templates/compose_banner/wildcard_mention_not_allowed_error.hbs"; -import * as channel from "./channel"; -import * as compose_banner from "./compose_banner"; -import * as compose_notifications from "./compose_notifications"; -import * as compose_state from "./compose_state"; -import * as compose_ui from "./compose_ui"; -import * as compose_validate from "./compose_validate"; -import * as drafts from "./drafts"; -import * as echo from "./echo"; -import * as message_events from "./message_events"; -import * as onboarding_steps from "./onboarding_steps"; -import * as people from "./people"; -import * as scheduled_messages from "./scheduled_messages"; -import * as sent_messages from "./sent_messages"; -import * as server_events from "./server_events"; -import {current_user} from "./state_data"; -import * as transmit from "./transmit"; -import {user_settings} from "./user_settings"; -import * as util from "./util"; -import * as zcommand from "./zcommand"; +import * as channel from "./channel.ts"; +import * as compose_banner from "./compose_banner.ts"; +import * as compose_notifications from "./compose_notifications.ts"; +import * as compose_state from "./compose_state.ts"; +import * as compose_ui from "./compose_ui.ts"; +import * as compose_validate from "./compose_validate.ts"; +import * as drafts from "./drafts.ts"; +import * as echo from "./echo.ts"; +import * as message_events from "./message_events.js"; +import * as onboarding_steps from "./onboarding_steps.ts"; +import * as people from "./people.ts"; +import * as scheduled_messages from "./scheduled_messages.ts"; +import * as sent_messages from "./sent_messages.ts"; +import * as server_events from "./server_events.js"; +import {current_user} from "./state_data.ts"; +import * as transmit from "./transmit.js"; +import {user_settings} from "./user_settings.ts"; +import * as util from "./util.ts"; +import * as zcommand from "./zcommand.ts"; // Docs: https://zulip.readthedocs.io/en/latest/subsystems/sending-messages.html diff --git a/web/src/compose_actions.ts b/web/src/compose_actions.ts index 9738ccf9b1..4b5a7f3136 100644 --- a/web/src/compose_actions.ts +++ b/web/src/compose_actions.ts @@ -3,29 +3,29 @@ import autosize from "autosize"; import $ from "jquery"; -import * as blueslip from "./blueslip"; -import * as compose_banner from "./compose_banner"; -import * as compose_fade from "./compose_fade"; -import * as compose_notifications from "./compose_notifications"; -import * as compose_pm_pill from "./compose_pm_pill"; -import * as compose_recipient from "./compose_recipient"; -import * as compose_state from "./compose_state"; -import * as compose_ui from "./compose_ui"; -import type {ComposeTriggeredOptions} from "./compose_ui"; -import * as compose_validate from "./compose_validate"; -import * as drafts from "./drafts"; -import * as message_lists from "./message_lists"; -import type {Message} from "./message_store"; -import * as message_util from "./message_util"; -import * as message_viewport from "./message_viewport"; -import * as narrow_state from "./narrow_state"; -import {page_params} from "./page_params"; -import * as people from "./people"; -import * as popovers from "./popovers"; -import * as reload_state from "./reload_state"; -import * as resize from "./resize"; -import * as spectators from "./spectators"; -import * as stream_data from "./stream_data"; +import * as blueslip from "./blueslip.ts"; +import * as compose_banner from "./compose_banner.ts"; +import * as compose_fade from "./compose_fade.ts"; +import * as compose_notifications from "./compose_notifications.ts"; +import * as compose_pm_pill from "./compose_pm_pill.ts"; +import * as compose_recipient from "./compose_recipient.ts"; +import * as compose_state from "./compose_state.ts"; +import * as compose_ui from "./compose_ui.ts"; +import type {ComposeTriggeredOptions} from "./compose_ui.ts"; +import * as compose_validate from "./compose_validate.ts"; +import * as drafts from "./drafts.ts"; +import * as message_lists from "./message_lists.ts"; +import type {Message} from "./message_store.ts"; +import * as message_util from "./message_util.ts"; +import * as message_viewport from "./message_viewport.ts"; +import * as narrow_state from "./narrow_state.ts"; +import {page_params} from "./page_params.ts"; +import * as people from "./people.ts"; +import * as popovers from "./popovers.ts"; +import * as reload_state from "./reload_state.ts"; +import * as resize from "./resize.ts"; +import * as spectators from "./spectators.ts"; +import * as stream_data from "./stream_data.ts"; // Opts sent to `compose_actions.start`. type ComposeActionsStartOpts = { diff --git a/web/src/compose_banner.ts b/web/src/compose_banner.ts index fba50340aa..91d2f5d3ad 100644 --- a/web/src/compose_banner.ts +++ b/web/src/compose_banner.ts @@ -4,10 +4,10 @@ import render_cannot_send_direct_message_error from "../templates/compose_banner import render_compose_banner from "../templates/compose_banner/compose_banner.hbs"; import render_stream_does_not_exist_error from "../templates/compose_banner/stream_does_not_exist_error.hbs"; -import {$t} from "./i18n"; -import * as scroll_util from "./scroll_util"; -import * as stream_data from "./stream_data"; -import type {StreamSubscription} from "./sub_store"; +import {$t} from "./i18n.ts"; +import * as scroll_util from "./scroll_util.ts"; +import * as stream_data from "./stream_data.ts"; +import type {StreamSubscription} from "./sub_store.ts"; export let scroll_to_message_banner_message_id: number | null = null; export function set_scroll_to_message_banner_message_id(val: number | null): void { diff --git a/web/src/compose_call.ts b/web/src/compose_call.ts index b5012507e9..b8428a1e67 100644 --- a/web/src/compose_call.ts +++ b/web/src/compose_call.ts @@ -1,4 +1,4 @@ -import {realm} from "./state_data"; +import {realm} from "./state_data.ts"; export const zoom_token_callbacks = new Map(); export const video_call_xhrs = new Map>(); diff --git a/web/src/compose_call_ui.ts b/web/src/compose_call_ui.ts index ccdd609688..962eae3584 100644 --- a/web/src/compose_call_ui.ts +++ b/web/src/compose_call_ui.ts @@ -1,15 +1,15 @@ import $ from "jquery"; import {z} from "zod"; -import * as channel from "./channel"; -import * as compose_call from "./compose_call"; -import {get_recipient_label} from "./compose_closed_ui"; -import * as compose_ui from "./compose_ui"; -import {$t, $t_html} from "./i18n"; -import * as rows from "./rows"; -import {current_user, realm} from "./state_data"; -import * as ui_report from "./ui_report"; -import * as util from "./util"; +import * as channel from "./channel.ts"; +import * as compose_call from "./compose_call.ts"; +import {get_recipient_label} from "./compose_closed_ui.ts"; +import * as compose_ui from "./compose_ui.ts"; +import {$t, $t_html} from "./i18n.ts"; +import * as rows from "./rows.ts"; +import {current_user, realm} from "./state_data.ts"; +import * as ui_report from "./ui_report.ts"; +import * as util from "./util.ts"; const call_response_schema = z.object({ msg: z.string(), diff --git a/web/src/compose_closed_ui.ts b/web/src/compose_closed_ui.ts index 891755a847..a584e61a43 100644 --- a/web/src/compose_closed_ui.ts +++ b/web/src/compose_closed_ui.ts @@ -1,13 +1,13 @@ import $ from "jquery"; -import * as compose_actions from "./compose_actions"; -import {$t} from "./i18n"; -import * as message_lists from "./message_lists"; -import * as message_store from "./message_store"; -import * as message_util from "./message_util"; -import * as narrow_state from "./narrow_state"; -import * as people from "./people"; -import * as stream_data from "./stream_data"; +import * as compose_actions from "./compose_actions.ts"; +import {$t} from "./i18n.ts"; +import * as message_lists from "./message_lists.ts"; +import * as message_store from "./message_store.ts"; +import * as message_util from "./message_util.ts"; +import * as narrow_state from "./narrow_state.ts"; +import * as people from "./people.ts"; +import * as stream_data from "./stream_data.ts"; function format_stream_recipient_label(stream_id: number, topic: string): string { const stream = stream_data.get_sub_by_id(stream_id); diff --git a/web/src/compose_fade.ts b/web/src/compose_fade.ts index 5060c6bc4c..a478f31e55 100644 --- a/web/src/compose_fade.ts +++ b/web/src/compose_fade.ts @@ -2,14 +2,14 @@ import $ from "jquery"; import _ from "lodash"; import assert from "minimalistic-assert"; -import * as compose_fade_helper from "./compose_fade_helper"; -import * as compose_state from "./compose_state"; -import type {MessageGroup} from "./message_list_view"; -import * as message_lists from "./message_lists"; -import * as message_viewport from "./message_viewport"; -import * as people from "./people"; -import * as rows from "./rows"; -import * as util from "./util"; +import * as compose_fade_helper from "./compose_fade_helper.ts"; +import * as compose_state from "./compose_state.ts"; +import type {MessageGroup} from "./message_list_view.ts"; +import * as message_lists from "./message_lists.ts"; +import * as message_viewport from "./message_viewport.ts"; +import * as people from "./people.ts"; +import * as rows from "./rows.ts"; +import * as util from "./util.ts"; let normal_display = false; diff --git a/web/src/compose_fade_helper.ts b/web/src/compose_fade_helper.ts index 55e56f37d1..0d125cdfd0 100644 --- a/web/src/compose_fade_helper.ts +++ b/web/src/compose_fade_helper.ts @@ -1,7 +1,7 @@ -import type {Message} from "./message_store"; -import * as sub_store from "./sub_store"; -import type {Recipient} from "./util"; -import * as util from "./util"; +import type {Message} from "./message_store.ts"; +import * as sub_store from "./sub_store.ts"; +import type {Recipient} from "./util.ts"; +import * as util from "./util.ts"; let focused_recipient: Recipient | undefined; diff --git a/web/src/compose_notifications.ts b/web/src/compose_notifications.ts index c4cb67b331..93be66b1fe 100644 --- a/web/src/compose_notifications.ts +++ b/web/src/compose_notifications.ts @@ -7,18 +7,18 @@ import render_jump_to_sent_message_conversation_banner from "../templates/compos import render_message_sent_banner from "../templates/compose_banner/message_sent_banner.hbs"; import render_unmute_topic_banner from "../templates/compose_banner/unmute_topic_banner.hbs"; -import * as blueslip from "./blueslip"; -import * as compose_banner from "./compose_banner"; -import * as hash_util from "./hash_util"; -import {$t} from "./i18n"; -import * as message_lists from "./message_lists"; -import type {Message} from "./message_store"; -import * as narrow_state from "./narrow_state"; -import * as onboarding_steps from "./onboarding_steps"; -import * as people from "./people"; -import * as stream_data from "./stream_data"; -import {user_settings} from "./user_settings"; -import * as user_topics from "./user_topics"; +import * as blueslip from "./blueslip.ts"; +import * as compose_banner from "./compose_banner.ts"; +import * as hash_util from "./hash_util.ts"; +import {$t} from "./i18n.ts"; +import * as message_lists from "./message_lists.ts"; +import type {Message} from "./message_store.ts"; +import * as narrow_state from "./narrow_state.ts"; +import * as onboarding_steps from "./onboarding_steps.ts"; +import * as people from "./people.ts"; +import * as stream_data from "./stream_data.ts"; +import {user_settings} from "./user_settings.ts"; +import * as user_topics from "./user_topics.ts"; export function notify_unmute(muted_narrow: string, stream_id: number, topic_name: string): void { const $unmute_notification = $( diff --git a/web/src/compose_pm_pill.ts b/web/src/compose_pm_pill.ts index 8977c607e7..c701ef2168 100644 --- a/web/src/compose_pm_pill.ts +++ b/web/src/compose_pm_pill.ts @@ -1,12 +1,12 @@ import $ from "jquery"; -import type {InputPillConfig} from "./input_pill"; -import * as input_pill from "./input_pill"; -import type {User} from "./people"; -import * as people from "./people"; -import type {UserPill, UserPillWidget} from "./user_pill"; -import * as user_pill from "./user_pill"; -import * as util from "./util"; +import type {InputPillConfig} from "./input_pill.ts"; +import * as input_pill from "./input_pill.ts"; +import type {User} from "./people.ts"; +import * as people from "./people.ts"; +import type {UserPill, UserPillWidget} from "./user_pill.ts"; +import * as user_pill from "./user_pill.ts"; +import * as util from "./util.ts"; export let widget: UserPillWidget; diff --git a/web/src/compose_popovers.ts b/web/src/compose_popovers.ts index 798a6a9304..11bb7bb5cd 100644 --- a/web/src/compose_popovers.ts +++ b/web/src/compose_popovers.ts @@ -3,11 +3,11 @@ import assert from "minimalistic-assert"; import render_compose_control_buttons_popover from "../templates/popovers/compose_control_buttons/compose_control_buttons_popover.hbs"; -import * as giphy_state from "./giphy_state"; -import * as popover_menus from "./popover_menus"; -import * as popovers from "./popovers"; -import * as rows from "./rows"; -import {parse_html} from "./ui_util"; +import * as giphy_state from "./giphy_state.ts"; +import * as popover_menus from "./popover_menus.ts"; +import * as popovers from "./popovers.ts"; +import * as rows from "./rows.ts"; +import {parse_html} from "./ui_util.ts"; export function initialize(): void { // Click event handlers for it are handled in `compose_ui` and diff --git a/web/src/compose_recipient.ts b/web/src/compose_recipient.ts index 8a47c5cdd8..c5ca2c7f31 100644 --- a/web/src/compose_recipient.ts +++ b/web/src/compose_recipient.ts @@ -7,24 +7,24 @@ import type * as tippy from "tippy.js"; import render_inline_decorated_stream_name from "../templates/inline_decorated_stream_name.hbs"; -import * as compose_banner from "./compose_banner"; -import * as compose_fade from "./compose_fade"; -import * as compose_pm_pill from "./compose_pm_pill"; -import * as compose_state from "./compose_state"; -import * as compose_ui from "./compose_ui"; -import type {ComposeTriggeredOptions} from "./compose_ui"; -import * as compose_validate from "./compose_validate"; -import * as drafts from "./drafts"; -import * as dropdown_widget from "./dropdown_widget"; -import type {Option} from "./dropdown_widget"; -import {$t} from "./i18n"; -import * as narrow_state from "./narrow_state"; -import {realm} from "./state_data"; -import * as stream_data from "./stream_data"; -import * as sub_store from "./sub_store"; -import * as ui_util from "./ui_util"; -import * as user_groups from "./user_groups"; -import * as util from "./util"; +import * as compose_banner from "./compose_banner.ts"; +import * as compose_fade from "./compose_fade.ts"; +import * as compose_pm_pill from "./compose_pm_pill.ts"; +import * as compose_state from "./compose_state.ts"; +import * as compose_ui from "./compose_ui.ts"; +import type {ComposeTriggeredOptions} from "./compose_ui.ts"; +import * as compose_validate from "./compose_validate.ts"; +import * as drafts from "./drafts.ts"; +import * as dropdown_widget from "./dropdown_widget.ts"; +import type {Option} from "./dropdown_widget.ts"; +import {$t} from "./i18n.ts"; +import * as narrow_state from "./narrow_state.ts"; +import {realm} from "./state_data.ts"; +import * as stream_data from "./stream_data.ts"; +import * as sub_store from "./sub_store.ts"; +import * as ui_util from "./ui_util.ts"; +import * as user_groups from "./user_groups.ts"; +import * as util from "./util.ts"; type MessageType = "stream" | "private"; type DirectMessagesOption = { diff --git a/web/src/compose_reply.ts b/web/src/compose_reply.ts index aaa9a04f33..441049c457 100644 --- a/web/src/compose_reply.ts +++ b/web/src/compose_reply.ts @@ -2,25 +2,25 @@ import $ from "jquery"; import assert from "minimalistic-assert"; import {z} from "zod"; -import * as fenced_code from "../shared/src/fenced_code"; +import * as fenced_code from "../shared/src/fenced_code.ts"; -import * as channel from "./channel"; -import * as compose_actions from "./compose_actions"; -import * as compose_state from "./compose_state"; -import * as compose_ui from "./compose_ui"; -import * as copy_and_paste from "./copy_and_paste"; -import * as hash_util from "./hash_util"; -import {$t} from "./i18n"; -import * as inbox_ui from "./inbox_ui"; -import * as inbox_util from "./inbox_util"; -import * as message_lists from "./message_lists"; -import type {Message} from "./message_store"; -import * as narrow_state from "./narrow_state"; -import * as people from "./people"; -import * as recent_view_ui from "./recent_view_ui"; -import * as recent_view_util from "./recent_view_util"; -import * as stream_data from "./stream_data"; -import * as unread_ops from "./unread_ops"; +import * as channel from "./channel.ts"; +import * as compose_actions from "./compose_actions.ts"; +import * as compose_state from "./compose_state.ts"; +import * as compose_ui from "./compose_ui.ts"; +import * as copy_and_paste from "./copy_and_paste.ts"; +import * as hash_util from "./hash_util.ts"; +import {$t} from "./i18n.ts"; +import * as inbox_ui from "./inbox_ui.ts"; +import * as inbox_util from "./inbox_util.ts"; +import * as message_lists from "./message_lists.ts"; +import type {Message} from "./message_store.ts"; +import * as narrow_state from "./narrow_state.ts"; +import * as people from "./people.ts"; +import * as recent_view_ui from "./recent_view_ui.ts"; +import * as recent_view_util from "./recent_view_util.ts"; +import * as stream_data from "./stream_data.ts"; +import * as unread_ops from "./unread_ops.ts"; export let respond_to_message = (opts: { keep_composebox_empty?: boolean; diff --git a/web/src/compose_send_menu_popover.js b/web/src/compose_send_menu_popover.js index dbc579d018..7c4422c281 100644 --- a/web/src/compose_send_menu_popover.js +++ b/web/src/compose_send_menu_popover.js @@ -5,18 +5,18 @@ import render_send_later_popover from "../templates/popovers/send_later_popover. import render_send_later_modal from "../templates/send_later_modal.hbs"; import render_send_later_modal_options from "../templates/send_later_modal_options.hbs"; -import * as blueslip from "./blueslip"; -import * as channel from "./channel"; -import * as compose from "./compose"; -import * as compose_state from "./compose_state"; -import * as compose_validate from "./compose_validate"; -import * as drafts from "./drafts"; -import * as flatpickr from "./flatpickr"; -import * as modals from "./modals"; -import * as popover_menus from "./popover_menus"; -import * as scheduled_messages from "./scheduled_messages"; -import {parse_html} from "./ui_util"; -import {user_settings} from "./user_settings"; +import * as blueslip from "./blueslip.ts"; +import * as channel from "./channel.ts"; +import * as compose from "./compose.js"; +import * as compose_state from "./compose_state.ts"; +import * as compose_validate from "./compose_validate.ts"; +import * as drafts from "./drafts.ts"; +import * as flatpickr from "./flatpickr.ts"; +import * as modals from "./modals.ts"; +import * as popover_menus from "./popover_menus.ts"; +import * as scheduled_messages from "./scheduled_messages.ts"; +import {parse_html} from "./ui_util.ts"; +import {user_settings} from "./user_settings.ts"; export const SCHEDULING_MODAL_UPDATE_INTERVAL_IN_MILLISECONDS = 60 * 1000; const ENTER_SENDS_SELECTION_DELAY = 600; diff --git a/web/src/compose_setup.js b/web/src/compose_setup.js index 14983ee1af..eb2ac8708b 100644 --- a/web/src/compose_setup.js +++ b/web/src/compose_setup.js @@ -1,40 +1,40 @@ import $ from "jquery"; -import {unresolve_name} from "../shared/src/resolved_topic"; +import {unresolve_name} from "../shared/src/resolved_topic.ts"; import render_add_poll_modal from "../templates/add_poll_modal.hbs"; -import * as compose from "./compose"; -import * as compose_actions from "./compose_actions"; -import * as compose_banner from "./compose_banner"; -import * as compose_call from "./compose_call"; -import * as compose_call_ui from "./compose_call_ui"; -import * as compose_notifications from "./compose_notifications"; -import * as compose_recipient from "./compose_recipient"; -import * as compose_send_menu_popover from "./compose_send_menu_popover"; -import * as compose_state from "./compose_state"; -import * as compose_ui from "./compose_ui"; -import * as compose_validate from "./compose_validate"; -import * as dialog_widget from "./dialog_widget"; -import * as flatpickr from "./flatpickr"; -import {$t_html} from "./i18n"; -import * as message_edit from "./message_edit"; -import * as message_view from "./message_view"; -import * as narrow_state from "./narrow_state"; -import * as onboarding_steps from "./onboarding_steps"; -import {page_params} from "./page_params"; -import * as poll_modal from "./poll_modal"; -import * as popovers from "./popovers"; -import * as resize from "./resize"; -import * as rows from "./rows"; -import * as scheduled_messages from "./scheduled_messages"; -import * as stream_data from "./stream_data"; -import * as stream_settings_components from "./stream_settings_components"; -import * as sub_store from "./sub_store"; -import * as subscriber_api from "./subscriber_api"; -import {get_timestamp_for_flatpickr} from "./timerender"; -import * as ui_report from "./ui_report"; -import * as upload from "./upload"; -import * as user_topics from "./user_topics"; +import * as compose from "./compose.js"; +import * as compose_actions from "./compose_actions.ts"; +import * as compose_banner from "./compose_banner.ts"; +import * as compose_call from "./compose_call.ts"; +import * as compose_call_ui from "./compose_call_ui.ts"; +import * as compose_notifications from "./compose_notifications.ts"; +import * as compose_recipient from "./compose_recipient.ts"; +import * as compose_send_menu_popover from "./compose_send_menu_popover.js"; +import * as compose_state from "./compose_state.ts"; +import * as compose_ui from "./compose_ui.ts"; +import * as compose_validate from "./compose_validate.ts"; +import * as dialog_widget from "./dialog_widget.ts"; +import * as flatpickr from "./flatpickr.ts"; +import {$t_html} from "./i18n.ts"; +import * as message_edit from "./message_edit.ts"; +import * as message_view from "./message_view.ts"; +import * as narrow_state from "./narrow_state.ts"; +import * as onboarding_steps from "./onboarding_steps.ts"; +import {page_params} from "./page_params.ts"; +import * as poll_modal from "./poll_modal.ts"; +import * as popovers from "./popovers.ts"; +import * as resize from "./resize.ts"; +import * as rows from "./rows.ts"; +import * as scheduled_messages from "./scheduled_messages.ts"; +import * as stream_data from "./stream_data.ts"; +import * as stream_settings_components from "./stream_settings_components.ts"; +import * as sub_store from "./sub_store.ts"; +import * as subscriber_api from "./subscriber_api.ts"; +import {get_timestamp_for_flatpickr} from "./timerender.ts"; +import * as ui_report from "./ui_report.ts"; +import * as upload from "./upload.ts"; +import * as user_topics from "./user_topics.ts"; export function abort_xhr() { $("#compose-send-button").prop("disabled", false); diff --git a/web/src/compose_state.ts b/web/src/compose_state.ts index f0839e859b..3ebbab8600 100644 --- a/web/src/compose_state.ts +++ b/web/src/compose_state.ts @@ -1,9 +1,9 @@ import $ from "jquery"; -import * as compose_pm_pill from "./compose_pm_pill"; -import {$t} from "./i18n"; -import * as people from "./people"; -import * as sub_store from "./sub_store"; +import * as compose_pm_pill from "./compose_pm_pill.ts"; +import {$t} from "./i18n.ts"; +import * as people from "./people.ts"; +import * as sub_store from "./sub_store.ts"; let message_type: "stream" | "private" | undefined; let recipient_edited_manually = false; diff --git a/web/src/compose_tooltips.ts b/web/src/compose_tooltips.ts index c3d3756cd3..6abfa2e9f7 100644 --- a/web/src/compose_tooltips.ts +++ b/web/src/compose_tooltips.ts @@ -6,16 +6,16 @@ import * as tippy from "tippy.js"; import render_drafts_tooltip from "../templates/drafts_tooltip.hbs"; import render_narrow_to_compose_recipients_tooltip from "../templates/narrow_to_compose_recipients_tooltip.hbs"; -import * as compose_recipient from "./compose_recipient"; -import * as compose_state from "./compose_state"; -import * as compose_validate from "./compose_validate"; -import {$t} from "./i18n"; -import {pick_empty_narrow_banner} from "./narrow_banner"; -import * as narrow_state from "./narrow_state"; -import * as popover_menus from "./popover_menus"; -import {EXTRA_LONG_HOVER_DELAY, INSTANT_HOVER_DELAY, LONG_HOVER_DELAY} from "./tippyjs"; -import {parse_html} from "./ui_util"; -import {user_settings} from "./user_settings"; +import * as compose_recipient from "./compose_recipient.ts"; +import * as compose_state from "./compose_state.ts"; +import * as compose_validate from "./compose_validate.ts"; +import {$t} from "./i18n.ts"; +import {pick_empty_narrow_banner} from "./narrow_banner.ts"; +import * as narrow_state from "./narrow_state.ts"; +import * as popover_menus from "./popover_menus.ts"; +import {EXTRA_LONG_HOVER_DELAY, INSTANT_HOVER_DELAY, LONG_HOVER_DELAY} from "./tippyjs.ts"; +import {parse_html} from "./ui_util.ts"; +import {user_settings} from "./user_settings.ts"; export function initialize(): void { tippy.delegate("body", { diff --git a/web/src/compose_ui.ts b/web/src/compose_ui.ts index 0a59705ae4..e0bcacd778 100644 --- a/web/src/compose_ui.ts +++ b/web/src/compose_ui.ts @@ -12,23 +12,23 @@ import { } from "text-field-edit"; import {z} from "zod"; -import type {Typeahead} from "./bootstrap_typeahead"; -import * as bulleted_numbered_list_util from "./bulleted_numbered_list_util"; -import * as channel from "./channel"; -import * as common from "./common"; -import type {TypeaheadSuggestion} from "./composebox_typeahead"; -import {$t, $t_html} from "./i18n"; -import * as loading from "./loading"; -import * as markdown from "./markdown"; -import * as people from "./people"; -import * as popover_menus from "./popover_menus"; -import {postprocess_content} from "./postprocess_content"; -import * as rendered_markdown from "./rendered_markdown"; -import * as rtl from "./rtl"; -import {current_user} from "./state_data"; -import * as stream_data from "./stream_data"; -import * as user_status from "./user_status"; -import * as util from "./util"; +import type {Typeahead} from "./bootstrap_typeahead.ts"; +import * as bulleted_numbered_list_util from "./bulleted_numbered_list_util.ts"; +import * as channel from "./channel.ts"; +import * as common from "./common.ts"; +import type {TypeaheadSuggestion} from "./composebox_typeahead.ts"; +import {$t, $t_html} from "./i18n.ts"; +import * as loading from "./loading.ts"; +import * as markdown from "./markdown.ts"; +import * as people from "./people.ts"; +import * as popover_menus from "./popover_menus.ts"; +import {postprocess_content} from "./postprocess_content.ts"; +import * as rendered_markdown from "./rendered_markdown.ts"; +import * as rtl from "./rtl.ts"; +import {current_user} from "./state_data.ts"; +import * as stream_data from "./stream_data.ts"; +import * as user_status from "./user_status.ts"; +import * as util from "./util.ts"; export const DEFAULT_COMPOSE_PLACEHOLDER = $t({defaultMessage: "Compose your message here"}); diff --git a/web/src/compose_validate.ts b/web/src/compose_validate.ts index d7057cf141..3cd680bddc 100644 --- a/web/src/compose_validate.ts +++ b/web/src/compose_validate.ts @@ -1,6 +1,6 @@ import $ from "jquery"; -import * as resolved_topic from "../shared/src/resolved_topic"; +import * as resolved_topic from "../shared/src/resolved_topic.ts"; import render_compose_banner from "../templates/compose_banner/compose_banner.hbs"; import render_not_subscribed_warning from "../templates/compose_banner/not_subscribed_warning.hbs"; import render_private_stream_warning from "../templates/compose_banner/private_stream_warning.hbs"; @@ -8,27 +8,27 @@ import render_stream_wildcard_warning from "../templates/compose_banner/stream_w import render_wildcard_mention_not_allowed_error from "../templates/compose_banner/wildcard_mention_not_allowed_error.hbs"; import render_compose_limit_indicator from "../templates/compose_limit_indicator.hbs"; -import * as compose_banner from "./compose_banner"; -import * as compose_pm_pill from "./compose_pm_pill"; -import * as compose_state from "./compose_state"; -import * as compose_ui from "./compose_ui"; -import {$t} from "./i18n"; -import * as message_store from "./message_store"; -import * as message_util from "./message_util"; -import * as narrow_state from "./narrow_state"; -import * as peer_data from "./peer_data"; -import * as people from "./people"; -import * as reactions from "./reactions"; -import * as recent_senders from "./recent_senders"; -import * as settings_config from "./settings_config"; -import * as settings_data from "./settings_data"; -import {current_user, realm} from "./state_data"; -import * as stream_data from "./stream_data"; -import * as sub_store from "./sub_store"; -import type {StreamSubscription} from "./sub_store"; -import type {UserOrMention} from "./typeahead_helper"; -import * as user_groups from "./user_groups"; -import * as util from "./util"; +import * as compose_banner from "./compose_banner.ts"; +import * as compose_pm_pill from "./compose_pm_pill.ts"; +import * as compose_state from "./compose_state.ts"; +import * as compose_ui from "./compose_ui.ts"; +import {$t} from "./i18n.ts"; +import * as message_store from "./message_store.ts"; +import * as message_util from "./message_util.ts"; +import * as narrow_state from "./narrow_state.ts"; +import * as peer_data from "./peer_data.ts"; +import * as people from "./people.ts"; +import * as reactions from "./reactions.ts"; +import * as recent_senders from "./recent_senders.ts"; +import * as settings_config from "./settings_config.ts"; +import * as settings_data from "./settings_data.ts"; +import {current_user, realm} from "./state_data.ts"; +import * as stream_data from "./stream_data.ts"; +import * as sub_store from "./sub_store.ts"; +import type {StreamSubscription} from "./sub_store.ts"; +import type {UserOrMention} from "./typeahead_helper.ts"; +import * as user_groups from "./user_groups.ts"; +import * as util from "./util.ts"; let user_acknowledged_stream_wildcard = false; let upload_in_progress = false; diff --git a/web/src/composebox_typeahead.ts b/web/src/composebox_typeahead.ts index 703aff8acb..45b3627b91 100644 --- a/web/src/composebox_typeahead.ts +++ b/web/src/composebox_typeahead.ts @@ -2,46 +2,46 @@ import $ from "jquery"; import _ from "lodash"; import assert from "minimalistic-assert"; -import * as typeahead from "../shared/src/typeahead"; -import type {Emoji, EmojiSuggestion} from "../shared/src/typeahead"; +import * as typeahead from "../shared/src/typeahead.ts"; +import type {Emoji, EmojiSuggestion} from "../shared/src/typeahead.ts"; import render_topic_typeahead_hint from "../templates/topic_typeahead_hint.hbs"; -import {MAX_ITEMS, Typeahead} from "./bootstrap_typeahead"; -import type {TypeaheadInputElement} from "./bootstrap_typeahead"; -import * as bulleted_numbered_list_util from "./bulleted_numbered_list_util"; -import * as compose_pm_pill from "./compose_pm_pill"; -import * as compose_state from "./compose_state"; -import * as compose_ui from "./compose_ui"; -import * as compose_validate from "./compose_validate"; -import * as emoji from "./emoji"; -import type {EmojiDict} from "./emoji"; -import * as flatpickr from "./flatpickr"; -import {$t} from "./i18n"; -import * as keydown_util from "./keydown_util"; -import * as message_store from "./message_store"; -import * as muted_users from "./muted_users"; -import {page_params} from "./page_params"; -import * as people from "./people"; -import type {PseudoMentionUser, User} from "./people"; -import * as realm_playground from "./realm_playground"; -import * as rows from "./rows"; -import * as settings_data from "./settings_data"; -import {realm} from "./state_data"; -import * as stream_data from "./stream_data"; -import type {StreamPillData} from "./stream_pill"; -import * as stream_topic_history from "./stream_topic_history"; -import * as stream_topic_history_util from "./stream_topic_history_util"; -import * as timerender from "./timerender"; -import * as topic_link_util from "./topic_link_util"; -import * as typeahead_helper from "./typeahead_helper"; -import type {UserOrMentionPillData} from "./typeahead_helper"; -import type {UserGroupPillData} from "./user_group_pill"; -import * as user_groups from "./user_groups"; -import type {UserGroup} from "./user_groups"; -import * as user_pill from "./user_pill"; -import type {UserPillData} from "./user_pill"; -import {user_settings} from "./user_settings"; -import * as util from "./util"; +import {MAX_ITEMS, Typeahead} from "./bootstrap_typeahead.ts"; +import type {TypeaheadInputElement} from "./bootstrap_typeahead.ts"; +import * as bulleted_numbered_list_util from "./bulleted_numbered_list_util.ts"; +import * as compose_pm_pill from "./compose_pm_pill.ts"; +import * as compose_state from "./compose_state.ts"; +import * as compose_ui from "./compose_ui.ts"; +import * as compose_validate from "./compose_validate.ts"; +import * as emoji from "./emoji.ts"; +import type {EmojiDict} from "./emoji.ts"; +import * as flatpickr from "./flatpickr.ts"; +import {$t} from "./i18n.ts"; +import * as keydown_util from "./keydown_util.ts"; +import * as message_store from "./message_store.ts"; +import * as muted_users from "./muted_users.ts"; +import {page_params} from "./page_params.ts"; +import * as people from "./people.ts"; +import type {PseudoMentionUser, User} from "./people.ts"; +import * as realm_playground from "./realm_playground.ts"; +import * as rows from "./rows.ts"; +import * as settings_data from "./settings_data.ts"; +import {realm} from "./state_data.ts"; +import * as stream_data from "./stream_data.ts"; +import type {StreamPillData} from "./stream_pill.ts"; +import * as stream_topic_history from "./stream_topic_history.ts"; +import * as stream_topic_history_util from "./stream_topic_history_util.ts"; +import * as timerender from "./timerender.ts"; +import * as topic_link_util from "./topic_link_util.ts"; +import * as typeahead_helper from "./typeahead_helper.ts"; +import type {UserOrMentionPillData} from "./typeahead_helper.ts"; +import type {UserGroupPillData} from "./user_group_pill.ts"; +import * as user_groups from "./user_groups.ts"; +import type {UserGroup} from "./user_groups.ts"; +import * as user_pill from "./user_pill.ts"; +import type {UserPillData} from "./user_pill.ts"; +import {user_settings} from "./user_settings.ts"; +import * as util from "./util.ts"; // ********************************** // AN IMPORTANT NOTE ABOUT TYPEAHEADS diff --git a/web/src/condense.ts b/web/src/condense.ts index 56b0204ef6..9ec1b3cf91 100644 --- a/web/src/condense.ts +++ b/web/src/condense.ts @@ -3,12 +3,12 @@ import assert from "minimalistic-assert"; import render_message_length_toggle from "../templates/message_length_toggle.hbs"; -import * as message_flags from "./message_flags"; -import * as message_lists from "./message_lists"; -import type {Message} from "./message_store"; -import * as message_viewport from "./message_viewport"; -import * as rows from "./rows"; -import * as util from "./util"; +import * as message_flags from "./message_flags.ts"; +import * as message_lists from "./message_lists.ts"; +import type {Message} from "./message_store.ts"; +import * as message_viewport from "./message_viewport.ts"; +import * as rows from "./rows.ts"; +import * as util from "./util.ts"; /* This library implements two related, similar concepts: diff --git a/web/src/confirm_dialog.ts b/web/src/confirm_dialog.ts index 71b3fdeaae..8af2d8f327 100644 --- a/web/src/confirm_dialog.ts +++ b/web/src/confirm_dialog.ts @@ -1,6 +1,6 @@ -import * as dialog_widget from "./dialog_widget"; -import type {DialogWidgetConfig} from "./dialog_widget"; -import {$t_html} from "./i18n"; +import * as dialog_widget from "./dialog_widget.ts"; +import type {DialogWidgetConfig} from "./dialog_widget.ts"; +import {$t_html} from "./i18n.ts"; export function launch(conf: DialogWidgetConfig): string { return dialog_widget.launch({ diff --git a/web/src/copied_tooltip.ts b/web/src/copied_tooltip.ts index 63bc0fb176..94ccb91fe7 100644 --- a/web/src/copied_tooltip.ts +++ b/web/src/copied_tooltip.ts @@ -1,7 +1,7 @@ import $ from "jquery"; import * as tippy from "tippy.js"; -import {$t} from "./i18n"; +import {$t} from "./i18n.ts"; function show_copied_tooltip( copy_button: HTMLElement, diff --git a/web/src/copy_and_paste.ts b/web/src/copy_and_paste.ts index 14825f8fd2..40ae732af5 100644 --- a/web/src/copy_and_paste.ts +++ b/web/src/copy_and_paste.ts @@ -5,13 +5,13 @@ import assert from "minimalistic-assert"; import {insertTextIntoField} from "text-field-edit"; import TurndownService from "turndown"; -import * as compose_ui from "./compose_ui"; -import * as hash_util from "./hash_util"; -import * as message_lists from "./message_lists"; -import * as rows from "./rows"; -import * as stream_data from "./stream_data"; -import * as topic_link_util from "./topic_link_util"; -import * as util from "./util"; +import * as compose_ui from "./compose_ui.ts"; +import * as hash_util from "./hash_util.ts"; +import * as message_lists from "./message_lists.ts"; +import * as rows from "./rows.ts"; +import * as stream_data from "./stream_data.ts"; +import * as topic_link_util from "./topic_link_util.ts"; +import * as util from "./util.ts"; declare global { // eslint-disable-next-line @typescript-eslint/consistent-type-definitions diff --git a/web/src/custom_profile_fields_ui.ts b/web/src/custom_profile_fields_ui.ts index d7f13ff278..28c0b634b3 100644 --- a/web/src/custom_profile_fields_ui.ts +++ b/web/src/custom_profile_fields_ui.ts @@ -4,16 +4,16 @@ import {z} from "zod"; import render_settings_custom_user_profile_field from "../templates/settings/custom_user_profile_field.hbs"; -import {Typeahead} from "./bootstrap_typeahead"; -import * as bootstrap_typeahead from "./bootstrap_typeahead"; -import {$t} from "./i18n"; -import * as people from "./people"; -import * as pill_typeahead from "./pill_typeahead"; -import * as settings_components from "./settings_components"; -import {current_user, realm} from "./state_data"; -import * as typeahead_helper from "./typeahead_helper"; -import type {UserPillWidget} from "./user_pill"; -import * as user_pill from "./user_pill"; +import {Typeahead} from "./bootstrap_typeahead.ts"; +import * as bootstrap_typeahead from "./bootstrap_typeahead.ts"; +import {$t} from "./i18n.ts"; +import * as people from "./people.ts"; +import * as pill_typeahead from "./pill_typeahead.ts"; +import * as settings_components from "./settings_components.ts"; +import {current_user, realm} from "./state_data.ts"; +import * as typeahead_helper from "./typeahead_helper.ts"; +import type {UserPillWidget} from "./user_pill.ts"; +import * as user_pill from "./user_pill.ts"; const user_value_schema = z.array(z.number()); diff --git a/web/src/demo_organizations_ui.ts b/web/src/demo_organizations_ui.ts index 5412dcf0c2..44f86a4afb 100644 --- a/web/src/demo_organizations_ui.ts +++ b/web/src/demo_organizations_ui.ts @@ -4,17 +4,17 @@ import {z} from "zod"; import render_convert_demo_organization_form from "../templates/settings/convert_demo_organization_form.hbs"; import render_demo_organization_warning from "../templates/settings/demo_organization_warning.hbs"; -import * as channel from "./channel"; -import * as dialog_widget from "./dialog_widget"; -import {$t} from "./i18n"; -import * as keydown_util from "./keydown_util"; -import {get_demo_organization_deadline_days_remaining} from "./navbar_alerts"; -import * as settings_config from "./settings_config"; -import * as settings_data from "./settings_data"; -import * as settings_org from "./settings_org"; -import type {RequestOpts} from "./settings_ui"; -import {current_user, realm} from "./state_data"; -import type {HTMLSelectOneElement} from "./types"; +import * as channel from "./channel.ts"; +import * as dialog_widget from "./dialog_widget.ts"; +import {$t} from "./i18n.ts"; +import * as keydown_util from "./keydown_util.ts"; +import {get_demo_organization_deadline_days_remaining} from "./navbar_alerts.ts"; +import * as settings_config from "./settings_config.ts"; +import * as settings_data from "./settings_data.ts"; +import * as settings_org from "./settings_org.ts"; +import type {RequestOpts} from "./settings_ui.ts"; +import {current_user, realm} from "./state_data.ts"; +import type {HTMLSelectOneElement} from "./types.ts"; export function insert_demo_organization_warning(): void { const days_remaining = get_demo_organization_deadline_days_remaining(); diff --git a/web/src/deprecated_feature_notice.ts b/web/src/deprecated_feature_notice.ts index 1ac87b23b3..73bd704bb5 100644 --- a/web/src/deprecated_feature_notice.ts +++ b/web/src/deprecated_feature_notice.ts @@ -1,9 +1,9 @@ import {z} from "zod"; -import * as blueslip from "./blueslip"; -import * as dialog_widget from "./dialog_widget"; -import {$t_html} from "./i18n"; -import {localstorage} from "./localstorage"; +import * as blueslip from "./blueslip.ts"; +import * as dialog_widget from "./dialog_widget.ts"; +import {$t_html} from "./i18n.ts"; +import {localstorage} from "./localstorage.ts"; export function get_hotkey_deprecation_notice( originalHotkey: string, diff --git a/web/src/desktop_integration.js b/web/src/desktop_integration.js index b90ef173d0..c9b1a03e28 100644 --- a/web/src/desktop_integration.js +++ b/web/src/desktop_integration.js @@ -1,13 +1,13 @@ import $ from "jquery"; -import * as browser_history from "./browser_history"; -import * as channel from "./channel"; -import {electron_bridge} from "./electron_bridge"; -import * as feedback_widget from "./feedback_widget"; -import {$t} from "./i18n"; -import * as message_store from "./message_store"; -import * as message_view from "./message_view"; -import * as stream_data from "./stream_data"; +import * as browser_history from "./browser_history.ts"; +import * as channel from "./channel.ts"; +import {electron_bridge} from "./electron_bridge.ts"; +import * as feedback_widget from "./feedback_widget.ts"; +import {$t} from "./i18n.ts"; +import * as message_store from "./message_store.ts"; +import * as message_view from "./message_view.ts"; +import * as stream_data from "./stream_data.ts"; export function initialize() { if (electron_bridge === undefined) { diff --git a/web/src/desktop_notifications.ts b/web/src/desktop_notifications.ts index 368385aa0b..3c24cdbebc 100644 --- a/web/src/desktop_notifications.ts +++ b/web/src/desktop_notifications.ts @@ -1,8 +1,8 @@ import $ from "jquery"; import assert from "minimalistic-assert"; -import {electron_bridge} from "./electron_bridge"; -import type {Message} from "./message_store"; +import {electron_bridge} from "./electron_bridge.ts"; +import type {Message} from "./message_store.ts"; type NoticeMemory = Map< string, diff --git a/web/src/dialog_widget.ts b/web/src/dialog_widget.ts index a1155752af..97217fd579 100644 --- a/web/src/dialog_widget.ts +++ b/web/src/dialog_widget.ts @@ -3,11 +3,11 @@ import _ from "lodash"; import render_dialog_widget from "../templates/dialog_widget.hbs"; -import type {AjaxRequestHandler} from "./channel"; -import {$t_html} from "./i18n"; -import * as loading from "./loading"; -import * as modals from "./modals"; -import * as ui_report from "./ui_report"; +import type {AjaxRequestHandler} from "./channel.ts"; +import {$t_html} from "./i18n.ts"; +import * as loading from "./loading.ts"; +import * as modals from "./modals.ts"; +import * as ui_report from "./ui_report.ts"; // Since only one dialog widget can be active at a time // and we don't support reopening already closed dialog widgets, diff --git a/web/src/direct_message_group_data.ts b/web/src/direct_message_group_data.ts index fbb5513f54..b5f91d92d2 100644 --- a/web/src/direct_message_group_data.ts +++ b/web/src/direct_message_group_data.ts @@ -1,7 +1,7 @@ import _ from "lodash"; -import type {Message} from "./message_store"; -import * as people from "./people"; +import type {Message} from "./message_store.ts"; +import * as people from "./people.ts"; const direct_message_group_timestamps = new Map(); diff --git a/web/src/drafts.ts b/web/src/drafts.ts index f6daa8e87b..81fea3daed 100644 --- a/web/src/drafts.ts +++ b/web/src/drafts.ts @@ -7,20 +7,20 @@ import {z} from "zod"; import render_confirm_delete_all_drafts from "../templates/confirm_dialog/confirm_delete_all_drafts.hbs"; -import * as blueslip from "./blueslip"; -import * as compose_state from "./compose_state"; -import * as confirm_dialog from "./confirm_dialog"; -import {$t, $t_html} from "./i18n"; -import {localstorage} from "./localstorage"; -import * as markdown from "./markdown"; -import * as narrow_state from "./narrow_state"; -import * as people from "./people"; -import * as stream_color from "./stream_color"; -import * as stream_data from "./stream_data"; -import * as sub_store from "./sub_store"; -import * as timerender from "./timerender"; -import * as ui_util from "./ui_util"; -import * as util from "./util"; +import * as blueslip from "./blueslip.ts"; +import * as compose_state from "./compose_state.ts"; +import * as confirm_dialog from "./confirm_dialog.ts"; +import {$t, $t_html} from "./i18n.ts"; +import {localstorage} from "./localstorage.ts"; +import * as markdown from "./markdown.ts"; +import * as narrow_state from "./narrow_state.ts"; +import * as people from "./people.ts"; +import * as stream_color from "./stream_color.ts"; +import * as stream_data from "./stream_data.ts"; +import * as sub_store from "./sub_store.ts"; +import * as timerender from "./timerender.ts"; +import * as ui_util from "./ui_util.ts"; +import * as util from "./util.ts"; export let set_count = (count: number): void => { const $drafts_li = $(".top_left_drafts"); diff --git a/web/src/drafts_overlay_ui.js b/web/src/drafts_overlay_ui.js index a14ceaaea2..feae3d11dc 100644 --- a/web/src/drafts_overlay_ui.js +++ b/web/src/drafts_overlay_ui.js @@ -3,17 +3,17 @@ import _ from "lodash"; import render_draft_table_body from "../templates/draft_table_body.hbs"; -import * as browser_history from "./browser_history"; -import * as compose_actions from "./compose_actions"; -import * as drafts from "./drafts"; -import {$t} from "./i18n"; -import * as message_view from "./message_view"; -import * as messages_overlay_ui from "./messages_overlay_ui"; -import * as overlays from "./overlays"; -import * as people from "./people"; -import * as rendered_markdown from "./rendered_markdown"; -import * as user_card_popover from "./user_card_popover"; -import * as user_group_popover from "./user_group_popover"; +import * as browser_history from "./browser_history.ts"; +import * as compose_actions from "./compose_actions.ts"; +import * as drafts from "./drafts.ts"; +import {$t} from "./i18n.ts"; +import * as message_view from "./message_view.ts"; +import * as messages_overlay_ui from "./messages_overlay_ui.ts"; +import * as overlays from "./overlays.ts"; +import * as people from "./people.ts"; +import * as rendered_markdown from "./rendered_markdown.ts"; +import * as user_card_popover from "./user_card_popover.js"; +import * as user_group_popover from "./user_group_popover.ts"; function restore_draft(draft_id) { const draft = drafts.draft_model.getDraft(draft_id); diff --git a/web/src/dropdown_widget.ts b/web/src/dropdown_widget.ts index 5bed73d16f..a1b42d6f24 100644 --- a/web/src/dropdown_widget.ts +++ b/web/src/dropdown_widget.ts @@ -8,14 +8,14 @@ import render_dropdown_list from "../templates/dropdown_list.hbs"; import render_dropdown_list_container from "../templates/dropdown_list_container.hbs"; import render_inline_decorated_stream_name from "../templates/inline_decorated_stream_name.hbs"; -import * as blueslip from "./blueslip"; -import * as ListWidget from "./list_widget"; -import type {ListWidget as ListWidgetType} from "./list_widget"; -import {page_params} from "./page_params"; -import * as popover_menus from "./popover_menus"; -import type {StreamSubscription} from "./sub_store"; -import {parse_html} from "./ui_util"; -import * as util from "./util"; +import * as blueslip from "./blueslip.ts"; +import * as ListWidget from "./list_widget.ts"; +import type {ListWidget as ListWidgetType} from "./list_widget.ts"; +import {page_params} from "./page_params.ts"; +import * as popover_menus from "./popover_menus.ts"; +import type {StreamSubscription} from "./sub_store.ts"; +import {parse_html} from "./ui_util.ts"; +import * as util from "./util.ts"; /* Sync with max-height set in zulip.css */ export const DEFAULT_DROPDOWN_HEIGHT = 210; diff --git a/web/src/echo.ts b/web/src/echo.ts index 3726fd3429..aa1165a4a6 100644 --- a/web/src/echo.ts +++ b/web/src/echo.ts @@ -5,31 +5,31 @@ import {z} from "zod"; import render_message_controls from "../templates/message_controls.hbs"; import render_message_controls_failed_msg from "../templates/message_controls_failed_msg.hbs"; -import * as alert_words from "./alert_words"; -import * as blueslip from "./blueslip"; -import * as compose_notifications from "./compose_notifications"; -import * as compose_ui from "./compose_ui"; -import * as echo_state from "./echo_state"; -import * as local_message from "./local_message"; -import * as markdown from "./markdown"; -import * as message_events_util from "./message_events_util"; -import * as message_list_data_cache from "./message_list_data_cache"; -import * as message_lists from "./message_lists"; -import * as message_live_update from "./message_live_update"; -import * as message_store from "./message_store"; -import type {DisplayRecipientUser, Message, RawMessage} from "./message_store"; -import * as message_util from "./message_util"; -import * as people from "./people"; -import * as pm_list from "./pm_list"; -import * as recent_view_data from "./recent_view_data"; -import * as rows from "./rows"; -import * as sent_messages from "./sent_messages"; -import {current_user} from "./state_data"; -import * as stream_data from "./stream_data"; -import * as stream_list from "./stream_list"; -import * as stream_topic_history from "./stream_topic_history"; -import type {TopicLink} from "./types"; -import * as util from "./util"; +import * as alert_words from "./alert_words.ts"; +import * as blueslip from "./blueslip.ts"; +import * as compose_notifications from "./compose_notifications.ts"; +import * as compose_ui from "./compose_ui.ts"; +import * as echo_state from "./echo_state.ts"; +import * as local_message from "./local_message.ts"; +import * as markdown from "./markdown.ts"; +import * as message_events_util from "./message_events_util.ts"; +import * as message_list_data_cache from "./message_list_data_cache.ts"; +import * as message_lists from "./message_lists.ts"; +import * as message_live_update from "./message_live_update.ts"; +import * as message_store from "./message_store.ts"; +import type {DisplayRecipientUser, Message, RawMessage} from "./message_store.ts"; +import * as message_util from "./message_util.ts"; +import * as people from "./people.ts"; +import * as pm_list from "./pm_list.ts"; +import * as recent_view_data from "./recent_view_data.ts"; +import * as rows from "./rows.ts"; +import * as sent_messages from "./sent_messages.ts"; +import {current_user} from "./state_data.ts"; +import * as stream_data from "./stream_data.ts"; +import * as stream_list from "./stream_list.ts"; +import * as stream_topic_history from "./stream_topic_history.ts"; +import type {TopicLink} from "./types.ts"; +import * as util from "./util.ts"; // Docs: https://zulip.readthedocs.io/en/latest/subsystems/sending-messages.html diff --git a/web/src/echo_state.ts b/web/src/echo_state.ts index 83c49b8971..7c69025a72 100644 --- a/web/src/echo_state.ts +++ b/web/src/echo_state.ts @@ -1,6 +1,6 @@ import assert from "minimalistic-assert"; -import type {Message} from "./message_store"; +import type {Message} from "./message_store.ts"; const waiting_for_id = new Map(); let waiting_for_ack = new Map(); diff --git a/web/src/email_pill.ts b/web/src/email_pill.ts index ba22e8c0a4..5e0bf8e1c4 100644 --- a/web/src/email_pill.ts +++ b/web/src/email_pill.ts @@ -1,5 +1,5 @@ -import type {InputPillConfig, InputPillContainer} from "./input_pill"; -import * as input_pill from "./input_pill"; +import type {InputPillConfig, InputPillContainer} from "./input_pill.ts"; +import * as input_pill from "./input_pill.ts"; type EmailPill = { type: "email"; diff --git a/web/src/emoji.ts b/web/src/emoji.ts index 9d3aedc41b..c1e09bfca4 100644 --- a/web/src/emoji.ts +++ b/web/src/emoji.ts @@ -1,8 +1,8 @@ import _ from "lodash"; import type {z} from "zod"; -import * as blueslip from "./blueslip"; -import type {StateData, realm_emoji_map_schema, server_emoji_schema} from "./state_data"; +import * as blueslip from "./blueslip.ts"; +import type {StateData, realm_emoji_map_schema, server_emoji_schema} from "./state_data.ts"; // This is the data structure that we get from the server on initialization. export type ServerEmoji = z.infer; diff --git a/web/src/emoji_picker.ts b/web/src/emoji_picker.ts index 0982250b1d..574f4f1138 100644 --- a/web/src/emoji_picker.ts +++ b/web/src/emoji_picker.ts @@ -4,29 +4,29 @@ import type * as tippy from "tippy.js"; import {z} from "zod"; import emoji_codes from "../../static/generated/emoji/emoji_codes.json"; -import * as typeahead from "../shared/src/typeahead"; +import * as typeahead from "../shared/src/typeahead.ts"; import render_emoji_popover from "../templates/popovers/emoji/emoji_popover.hbs"; import render_emoji_popover_emoji_map from "../templates/popovers/emoji/emoji_popover_emoji_map.hbs"; import render_emoji_popover_search_results from "../templates/popovers/emoji/emoji_popover_search_results.hbs"; import render_emoji_showcase from "../templates/popovers/emoji/emoji_showcase.hbs"; -import * as blueslip from "./blueslip"; -import * as compose_ui from "./compose_ui"; -import * as composebox_typeahead from "./composebox_typeahead"; -import * as emoji from "./emoji"; -import type {EmojiDict} from "./emoji"; -import * as keydown_util from "./keydown_util"; -import * as message_store from "./message_store"; -import {page_params} from "./page_params"; -import * as popover_menus from "./popover_menus"; -import * as reactions from "./reactions"; -import * as rows from "./rows"; -import * as scroll_util from "./scroll_util"; -import * as spectators from "./spectators"; -import * as ui_util from "./ui_util"; -import {user_settings} from "./user_settings"; -import * as user_status_ui from "./user_status_ui"; -import * as util from "./util"; +import * as blueslip from "./blueslip.ts"; +import * as compose_ui from "./compose_ui.ts"; +import * as composebox_typeahead from "./composebox_typeahead.ts"; +import * as emoji from "./emoji.ts"; +import type {EmojiDict} from "./emoji.ts"; +import * as keydown_util from "./keydown_util.ts"; +import * as message_store from "./message_store.ts"; +import {page_params} from "./page_params.ts"; +import * as popover_menus from "./popover_menus.ts"; +import * as reactions from "./reactions.ts"; +import * as rows from "./rows.ts"; +import * as scroll_util from "./scroll_util.ts"; +import * as spectators from "./spectators.ts"; +import * as ui_util from "./ui_util.ts"; +import {user_settings} from "./user_settings.ts"; +import * as user_status_ui from "./user_status_ui.ts"; +import * as util from "./util.ts"; // The functionalities for reacting to a message with an emoji // and composing a message with an emoji share a single widget, diff --git a/web/src/emojisets.ts b/web/src/emojisets.ts index c5760c2668..7cb3f9d2eb 100644 --- a/web/src/emojisets.ts +++ b/web/src/emojisets.ts @@ -3,8 +3,8 @@ import google_blob_sheet from "../generated/emoji/google-blob.webp"; import google_sheet from "../generated/emoji/google.webp"; import twitter_sheet from "../generated/emoji/twitter.webp"; -import * as blueslip from "./blueslip"; -import {user_settings} from "./user_settings"; +import * as blueslip from "./blueslip.ts"; +import {user_settings} from "./user_settings.ts"; import google_blob_css from "!style-loader?injectType=lazyStyleTag!css-loader!../generated/emoji-styles/google-blob-sprite.css"; import google_css from "!style-loader?injectType=lazyStyleTag!css-loader!../generated/emoji-styles/google-sprite.css"; diff --git a/web/src/favicon.ts b/web/src/favicon.ts index 7f9f3c01c0..9f13f1c9b8 100644 --- a/web/src/favicon.ts +++ b/web/src/favicon.ts @@ -3,8 +3,8 @@ import $ from "jquery"; import static_favicon_image from "../../static/images/favicon.svg"; import render_favicon_svg from "../templates/favicon.svg.hbs"; -import * as blueslip from "./blueslip"; -import favicon_font_url from "./favicon_font_url!=!url-loader!font-subset-loader2?glyphs=0123456789KMGT∞!source-sans/TTF/SourceSans3-Bold.ttf"; +import * as blueslip from "./blueslip.ts"; +import favicon_font_url from "./favicon_font_url!=!url-loader!font-subset-loader2?glyphs=0123456789KMGT∞!source-sans/TTF/SourceSans3-Bold.ttf"; // eslint-disable-line import/extensions let favicon_state: {image: HTMLImageElement; url: string} | undefined; diff --git a/web/src/feedback_widget.ts b/web/src/feedback_widget.ts index 25fba86821..9ac8deaa69 100644 --- a/web/src/feedback_widget.ts +++ b/web/src/feedback_widget.ts @@ -2,7 +2,7 @@ import $ from "jquery"; import render_feedback_container from "../templates/feedback_container.hbs"; -import * as blueslip from "./blueslip"; +import * as blueslip from "./blueslip.ts"; /* diff --git a/web/src/fetch_status.ts b/web/src/fetch_status.ts index 4ae7298cc7..79425e79d6 100644 --- a/web/src/fetch_status.ts +++ b/web/src/fetch_status.ts @@ -1,5 +1,5 @@ -import * as message_feed_loading from "./message_feed_loading"; -import type {Message, RawMessage} from "./message_store"; +import * as message_feed_loading from "./message_feed_loading.ts"; +import type {Message, RawMessage} from "./message_store.ts"; function max_id_for_messages(messages: (Message | RawMessage)[]): number { let max_id = 0; diff --git a/web/src/filter.ts b/web/src/filter.ts index 8f145b1ae0..b407c29af9 100644 --- a/web/src/filter.ts +++ b/web/src/filter.ts @@ -1,25 +1,25 @@ -import Handlebars from "handlebars/runtime"; +import Handlebars from "handlebars/runtime.js"; import _ from "lodash"; import assert from "minimalistic-assert"; -import * as resolved_topic from "../shared/src/resolved_topic"; +import * as resolved_topic from "../shared/src/resolved_topic.ts"; import render_search_description from "../templates/search_description.hbs"; -import * as blueslip from "./blueslip"; -import * as hash_parser from "./hash_parser"; -import {$t} from "./i18n"; -import * as message_parser from "./message_parser"; -import * as message_store from "./message_store"; -import type {Message} from "./message_store"; -import {page_params} from "./page_params"; -import type {User} from "./people"; -import * as people from "./people"; -import type {UserPillItem} from "./search_suggestion"; -import {current_user, realm} from "./state_data"; -import type {NarrowTerm} from "./state_data"; -import * as stream_data from "./stream_data"; -import * as user_topics from "./user_topics"; -import * as util from "./util"; +import * as blueslip from "./blueslip.ts"; +import * as hash_parser from "./hash_parser.ts"; +import {$t} from "./i18n.ts"; +import * as message_parser from "./message_parser.ts"; +import * as message_store from "./message_store.ts"; +import type {Message} from "./message_store.ts"; +import {page_params} from "./page_params.ts"; +import type {User} from "./people.ts"; +import * as people from "./people.ts"; +import type {UserPillItem} from "./search_suggestion.ts"; +import {current_user, realm} from "./state_data.ts"; +import type {NarrowTerm} from "./state_data.ts"; +import * as stream_data from "./stream_data.ts"; +import * as user_topics from "./user_topics.ts"; +import * as util from "./util.ts"; type IconData = { title: string; diff --git a/web/src/flatpickr.ts b/web/src/flatpickr.ts index a394a29152..bed7e3904a 100644 --- a/web/src/flatpickr.ts +++ b/web/src/flatpickr.ts @@ -4,9 +4,9 @@ import confirmDatePlugin from "flatpickr/dist/plugins/confirmDate/confirmDate"; import $ from "jquery"; import assert from "minimalistic-assert"; -import {$t} from "./i18n"; -import {user_settings} from "./user_settings"; -import * as util from "./util"; +import {$t} from "./i18n.ts"; +import {user_settings} from "./user_settings.ts"; +import * as util from "./util.ts"; export let flatpickr_instance: flatpickr.Instance; diff --git a/web/src/gear_menu.js b/web/src/gear_menu.js index 1ef1428c3c..e82fd36b9f 100644 --- a/web/src/gear_menu.js +++ b/web/src/gear_menu.js @@ -3,14 +3,14 @@ import WinChan from "winchan"; import render_navbar_gear_menu_popover from "../templates/popovers/navbar/navbar_gear_menu_popover.hbs"; -import * as blueslip from "./blueslip"; -import * as channel from "./channel"; -import * as popover_menus from "./popover_menus"; -import * as popover_menus_data from "./popover_menus_data"; -import * as popovers from "./popovers"; -import * as settings_preferences from "./settings_preferences"; -import * as theme from "./theme"; -import {parse_html} from "./ui_util"; +import * as blueslip from "./blueslip.ts"; +import * as channel from "./channel.ts"; +import * as popover_menus from "./popover_menus.ts"; +import * as popover_menus_data from "./popover_menus_data.ts"; +import * as popovers from "./popovers.ts"; +import * as settings_preferences from "./settings_preferences.ts"; +import * as theme from "./theme.ts"; +import {parse_html} from "./ui_util.ts"; /* For various historical reasons there isn't one diff --git a/web/src/gear_menu_util.ts b/web/src/gear_menu_util.ts index c73c72206d..0dcbbf8334 100644 --- a/web/src/gear_menu_util.ts +++ b/web/src/gear_menu_util.ts @@ -1,5 +1,5 @@ -import {$t} from "./i18n"; -import {realm} from "./state_data"; +import {$t} from "./i18n.ts"; +import {realm} from "./state_data.ts"; export function version_display_string(): string { const version = realm.zulip_version; diff --git a/web/src/giphy.js b/web/src/giphy.js index 6a32240d12..79444dd1b7 100644 --- a/web/src/giphy.js +++ b/web/src/giphy.js @@ -3,12 +3,12 @@ import _ from "lodash"; import render_giphy_picker from "../templates/giphy_picker.hbs"; -import * as blueslip from "./blueslip"; -import * as compose_ui from "./compose_ui"; -import * as popover_menus from "./popover_menus"; -import * as rows from "./rows"; -import {realm} from "./state_data"; -import * as ui_util from "./ui_util"; +import * as blueslip from "./blueslip.ts"; +import * as compose_ui from "./compose_ui.ts"; +import * as popover_menus from "./popover_menus.ts"; +import * as rows from "./rows.ts"; +import {realm} from "./state_data.ts"; +import * as ui_util from "./ui_util.ts"; let giphy_fetch; let search_term = ""; diff --git a/web/src/giphy_state.ts b/web/src/giphy_state.ts index b7af1be0e6..0b0914e195 100644 --- a/web/src/giphy_state.ts +++ b/web/src/giphy_state.ts @@ -1,4 +1,4 @@ -import {realm} from "./state_data"; +import {realm} from "./state_data.ts"; export function is_giphy_enabled(): boolean { return ( diff --git a/web/src/global.ts b/web/src/global.ts index 879df997c9..3967b516e9 100644 --- a/web/src/global.ts +++ b/web/src/global.ts @@ -1,6 +1,6 @@ /// -import type * as zulip_test_module from "./zulip_test"; +import type * as zulip_test_module from "./zulip_test.ts"; type JQueryCaretRange = { start: number; diff --git a/web/src/group_permission_settings.ts b/web/src/group_permission_settings.ts index 81b6fb2af2..b311058576 100644 --- a/web/src/group_permission_settings.ts +++ b/web/src/group_permission_settings.ts @@ -1,5 +1,5 @@ -import {realm} from "./state_data"; -import type {GroupPermissionSetting} from "./state_data"; +import {realm} from "./state_data.ts"; +import type {GroupPermissionSetting} from "./state_data.ts"; export function get_group_permission_setting_config( setting_name: string, diff --git a/web/src/group_setting_pill.ts b/web/src/group_setting_pill.ts index da9492aee4..771b1ef60e 100644 --- a/web/src/group_setting_pill.ts +++ b/web/src/group_setting_pill.ts @@ -2,18 +2,18 @@ import assert from "minimalistic-assert"; import render_input_pill from "../templates/input_pill.hbs"; -import * as group_permission_settings from "./group_permission_settings"; -import * as input_pill from "./input_pill"; -import type {InputPillConfig} from "./input_pill"; -import * as people from "./people"; -import * as pill_typeahead from "./pill_typeahead"; -import type {GroupSettingPill, GroupSettingPillContainer} from "./typeahead_helper"; -import * as user_group_pill from "./user_group_pill"; -import type {UserGroupPill} from "./user_group_pill"; -import * as user_groups from "./user_groups"; -import type {UserGroup} from "./user_groups"; -import * as user_pill from "./user_pill"; -import type {UserPill} from "./user_pill"; +import * as group_permission_settings from "./group_permission_settings.ts"; +import * as input_pill from "./input_pill.ts"; +import type {InputPillConfig} from "./input_pill.ts"; +import * as people from "./people.ts"; +import * as pill_typeahead from "./pill_typeahead.ts"; +import type {GroupSettingPill, GroupSettingPillContainer} from "./typeahead_helper.ts"; +import * as user_group_pill from "./user_group_pill.ts"; +import type {UserGroupPill} from "./user_group_pill.ts"; +import * as user_groups from "./user_groups.ts"; +import type {UserGroup} from "./user_groups.ts"; +import * as user_pill from "./user_pill.ts"; +import type {UserPill} from "./user_pill.ts"; function check_group_allowed_for_setting( group_item: UserGroupPill, diff --git a/web/src/hash_util.ts b/web/src/hash_util.ts index e4e1b3558d..48dc6ce0a6 100644 --- a/web/src/hash_util.ts +++ b/web/src/hash_util.ts @@ -1,17 +1,17 @@ -import * as internal_url from "../shared/src/internal_url"; +import * as internal_url from "../shared/src/internal_url.ts"; -import * as blueslip from "./blueslip"; -import type {Message} from "./message_store"; -import {page_params} from "./page_params"; -import * as people from "./people"; -import * as settings_data from "./settings_data"; -import type {NarrowTerm} from "./state_data"; -import * as stream_data from "./stream_data"; -import * as sub_store from "./sub_store"; -import type {StreamSubscription} from "./sub_store"; -import * as user_groups from "./user_groups"; -import type {UserGroup} from "./user_groups"; -import * as util from "./util"; +import * as blueslip from "./blueslip.ts"; +import type {Message} from "./message_store.ts"; +import {page_params} from "./page_params.ts"; +import * as people from "./people.ts"; +import * as settings_data from "./settings_data.ts"; +import type {NarrowTerm} from "./state_data.ts"; +import * as stream_data from "./stream_data.ts"; +import * as sub_store from "./sub_store.ts"; +import type {StreamSubscription} from "./sub_store.ts"; +import * as user_groups from "./user_groups.ts"; +import type {UserGroup} from "./user_groups.ts"; +import * as util from "./util.ts"; export function build_reload_url(): string { let hash = window.location.hash; diff --git a/web/src/hashchange.js b/web/src/hashchange.js index 390d5b2c7d..e25e02adf6 100644 --- a/web/src/hashchange.js +++ b/web/src/hashchange.js @@ -1,38 +1,38 @@ import $ from "jquery"; -import * as about_zulip from "./about_zulip"; -import * as admin from "./admin"; -import * as blueslip from "./blueslip"; -import * as browser_history from "./browser_history"; -import * as drafts_overlay_ui from "./drafts_overlay_ui"; -import * as hash_parser from "./hash_parser"; -import * as hash_util from "./hash_util"; -import {$t_html} from "./i18n"; -import * as inbox_ui from "./inbox_ui"; -import * as inbox_util from "./inbox_util"; -import * as info_overlay from "./info_overlay"; -import * as message_fetch from "./message_fetch"; -import * as message_view from "./message_view"; -import * as message_viewport from "./message_viewport"; -import * as modals from "./modals"; -import * as overlays from "./overlays"; -import {page_params} from "./page_params"; -import * as people from "./people"; -import * as popovers from "./popovers"; -import * as recent_view_ui from "./recent_view_ui"; -import * as recent_view_util from "./recent_view_util"; -import * as scheduled_messages_overlay_ui from "./scheduled_messages_overlay_ui"; -import * as settings from "./settings"; -import * as settings_panel_menu from "./settings_panel_menu"; -import * as settings_toggle from "./settings_toggle"; -import * as sidebar_ui from "./sidebar_ui"; -import * as spectators from "./spectators"; -import {current_user} from "./state_data"; -import * as stream_settings_ui from "./stream_settings_ui"; -import * as ui_report from "./ui_report"; -import * as user_group_edit from "./user_group_edit"; -import * as user_profile from "./user_profile"; -import {user_settings} from "./user_settings"; +import * as about_zulip from "./about_zulip.ts"; +import * as admin from "./admin.js"; +import * as blueslip from "./blueslip.ts"; +import * as browser_history from "./browser_history.ts"; +import * as drafts_overlay_ui from "./drafts_overlay_ui.js"; +import * as hash_parser from "./hash_parser.ts"; +import * as hash_util from "./hash_util.ts"; +import {$t_html} from "./i18n.ts"; +import * as inbox_ui from "./inbox_ui.ts"; +import * as inbox_util from "./inbox_util.ts"; +import * as info_overlay from "./info_overlay.ts"; +import * as message_fetch from "./message_fetch.ts"; +import * as message_view from "./message_view.ts"; +import * as message_viewport from "./message_viewport.ts"; +import * as modals from "./modals.ts"; +import * as overlays from "./overlays.ts"; +import {page_params} from "./page_params.ts"; +import * as people from "./people.ts"; +import * as popovers from "./popovers.ts"; +import * as recent_view_ui from "./recent_view_ui.ts"; +import * as recent_view_util from "./recent_view_util.ts"; +import * as scheduled_messages_overlay_ui from "./scheduled_messages_overlay_ui.ts"; +import * as settings from "./settings.js"; +import * as settings_panel_menu from "./settings_panel_menu.js"; +import * as settings_toggle from "./settings_toggle.js"; +import * as sidebar_ui from "./sidebar_ui.ts"; +import * as spectators from "./spectators.ts"; +import {current_user} from "./state_data.ts"; +import * as stream_settings_ui from "./stream_settings_ui.js"; +import * as ui_report from "./ui_report.ts"; +import * as user_group_edit from "./user_group_edit.js"; +import * as user_profile from "./user_profile.ts"; +import {user_settings} from "./user_settings.ts"; // Read https://zulip.readthedocs.io/en/latest/subsystems/hashchange-system.html // or locally: docs/subsystems/hashchange-system.md diff --git a/web/src/hotkey.js b/web/src/hotkey.js index a7b751c2be..cba3ab470f 100644 --- a/web/src/hotkey.js +++ b/web/src/hotkey.js @@ -1,68 +1,68 @@ import $ from "jquery"; import assert from "minimalistic-assert"; -import * as activity from "./activity"; -import * as activity_ui from "./activity_ui"; -import * as browser_history from "./browser_history"; -import * as common from "./common"; -import * as compose from "./compose"; -import * as compose_actions from "./compose_actions"; -import * as compose_banner from "./compose_banner"; -import * as compose_recipient from "./compose_recipient"; -import * as compose_reply from "./compose_reply"; -import * as compose_send_menu_popover from "./compose_send_menu_popover"; -import * as compose_state from "./compose_state"; -import * as compose_textarea from "./compose_textarea"; -import * as condense from "./condense"; -import * as copy_and_paste from "./copy_and_paste"; -import * as deprecated_feature_notice from "./deprecated_feature_notice"; -import * as drafts_overlay_ui from "./drafts_overlay_ui"; -import * as emoji from "./emoji"; -import * as emoji_picker from "./emoji_picker"; -import * as feedback_widget from "./feedback_widget"; -import * as gear_menu from "./gear_menu"; -import * as giphy from "./giphy"; -import * as hash_util from "./hash_util"; -import * as hashchange from "./hashchange"; -import * as inbox_ui from "./inbox_ui"; -import * as lightbox from "./lightbox"; -import * as list_util from "./list_util"; -import * as message_actions_popover from "./message_actions_popover"; -import * as message_edit from "./message_edit"; -import * as message_edit_history from "./message_edit_history"; -import * as message_lists from "./message_lists"; -import * as message_scroll_state from "./message_scroll_state"; -import * as message_view from "./message_view"; -import * as modals from "./modals"; -import * as narrow_state from "./narrow_state"; -import * as navbar_menus from "./navbar_menus"; -import * as navigate from "./navigate"; -import * as overlays from "./overlays"; -import {page_params} from "./page_params"; -import * as playground_links_popover from "./playground_links_popover"; -import * as pm_list from "./pm_list"; -import * as popover_menus from "./popover_menus"; -import * as popovers from "./popovers"; -import * as reactions from "./reactions"; -import * as read_receipts from "./read_receipts"; -import * as recent_view_ui from "./recent_view_ui"; -import * as recent_view_util from "./recent_view_util"; -import * as scheduled_messages_overlay_ui from "./scheduled_messages_overlay_ui"; -import * as search from "./search"; -import * as settings_data from "./settings_data"; -import * as sidebar_ui from "./sidebar_ui"; -import * as spectators from "./spectators"; -import * as starred_messages_ui from "./starred_messages_ui"; -import {realm} from "./state_data"; -import * as stream_list from "./stream_list"; -import * as stream_popover from "./stream_popover"; -import * as stream_settings_ui from "./stream_settings_ui"; -import * as topic_list from "./topic_list"; -import * as unread_ops from "./unread_ops"; -import * as user_card_popover from "./user_card_popover"; -import * as user_group_popover from "./user_group_popover"; -import {user_settings} from "./user_settings"; -import * as user_topics_ui from "./user_topics_ui"; +import * as activity from "./activity.ts"; +import * as activity_ui from "./activity_ui.ts"; +import * as browser_history from "./browser_history.ts"; +import * as common from "./common.ts"; +import * as compose from "./compose.js"; +import * as compose_actions from "./compose_actions.ts"; +import * as compose_banner from "./compose_banner.ts"; +import * as compose_recipient from "./compose_recipient.ts"; +import * as compose_reply from "./compose_reply.ts"; +import * as compose_send_menu_popover from "./compose_send_menu_popover.js"; +import * as compose_state from "./compose_state.ts"; +import * as compose_textarea from "./compose_textarea.ts"; +import * as condense from "./condense.ts"; +import * as copy_and_paste from "./copy_and_paste.ts"; +import * as deprecated_feature_notice from "./deprecated_feature_notice.ts"; +import * as drafts_overlay_ui from "./drafts_overlay_ui.js"; +import * as emoji from "./emoji.ts"; +import * as emoji_picker from "./emoji_picker.ts"; +import * as feedback_widget from "./feedback_widget.ts"; +import * as gear_menu from "./gear_menu.js"; +import * as giphy from "./giphy.js"; +import * as hash_util from "./hash_util.ts"; +import * as hashchange from "./hashchange.js"; +import * as inbox_ui from "./inbox_ui.ts"; +import * as lightbox from "./lightbox.ts"; +import * as list_util from "./list_util.ts"; +import * as message_actions_popover from "./message_actions_popover.js"; +import * as message_edit from "./message_edit.ts"; +import * as message_edit_history from "./message_edit_history.ts"; +import * as message_lists from "./message_lists.ts"; +import * as message_scroll_state from "./message_scroll_state.ts"; +import * as message_view from "./message_view.ts"; +import * as modals from "./modals.ts"; +import * as narrow_state from "./narrow_state.ts"; +import * as navbar_menus from "./navbar_menus.js"; +import * as navigate from "./navigate.js"; +import * as overlays from "./overlays.ts"; +import {page_params} from "./page_params.ts"; +import * as playground_links_popover from "./playground_links_popover.ts"; +import * as pm_list from "./pm_list.ts"; +import * as popover_menus from "./popover_menus.ts"; +import * as popovers from "./popovers.ts"; +import * as reactions from "./reactions.ts"; +import * as read_receipts from "./read_receipts.ts"; +import * as recent_view_ui from "./recent_view_ui.ts"; +import * as recent_view_util from "./recent_view_util.ts"; +import * as scheduled_messages_overlay_ui from "./scheduled_messages_overlay_ui.ts"; +import * as search from "./search.ts"; +import * as settings_data from "./settings_data.ts"; +import * as sidebar_ui from "./sidebar_ui.ts"; +import * as spectators from "./spectators.ts"; +import * as starred_messages_ui from "./starred_messages_ui.ts"; +import {realm} from "./state_data.ts"; +import * as stream_list from "./stream_list.ts"; +import * as stream_popover from "./stream_popover.js"; +import * as stream_settings_ui from "./stream_settings_ui.js"; +import * as topic_list from "./topic_list.ts"; +import * as unread_ops from "./unread_ops.ts"; +import * as user_card_popover from "./user_card_popover.js"; +import * as user_group_popover from "./user_group_popover.ts"; +import {user_settings} from "./user_settings.ts"; +import * as user_topics_ui from "./user_topics_ui.ts"; function do_narrow_action(action) { if (message_lists.current === undefined) { diff --git a/web/src/i18n.ts b/web/src/i18n.ts index 69cc99679b..92bbab137e 100644 --- a/web/src/i18n.ts +++ b/web/src/i18n.ts @@ -10,7 +10,7 @@ import type { } from "intl-messageformat"; import _ from "lodash"; -import {page_params} from "./base_page_params"; +import {page_params} from "./base_page_params.ts"; const cache = createIntlCache(); export const intl = createIntl( diff --git a/web/src/inbox_ui.ts b/web/src/inbox_ui.ts index 78405978c3..d69976bab3 100644 --- a/web/src/inbox_ui.ts +++ b/web/src/inbox_ui.ts @@ -10,32 +10,32 @@ import render_inbox_view from "../templates/inbox_view/inbox_view.hbs"; import render_introduce_zulip_view_modal from "../templates/introduce_zulip_view_modal.hbs"; import render_user_with_status_icon from "../templates/user_with_status_icon.hbs"; -import * as buddy_data from "./buddy_data"; -import * as compose_closed_ui from "./compose_closed_ui"; -import * as compose_state from "./compose_state"; -import * as dialog_widget from "./dialog_widget"; -import * as dropdown_widget from "./dropdown_widget"; -import * as hash_util from "./hash_util"; -import {$t_html} from "./i18n"; -import {is_visible, set_visible} from "./inbox_util"; -import * as keydown_util from "./keydown_util"; -import * as left_sidebar_navigation_area from "./left_sidebar_navigation_area"; -import {localstorage} from "./localstorage"; -import * as message_store from "./message_store"; -import type {Message} from "./message_store"; -import * as onboarding_steps from "./onboarding_steps"; -import * as people from "./people"; -import * as stream_color from "./stream_color"; -import * as stream_data from "./stream_data"; -import * as sub_store from "./sub_store"; -import * as unread from "./unread"; -import * as unread_ops from "./unread_ops"; -import {user_settings} from "./user_settings"; -import * as user_status from "./user_status"; -import * as user_topics from "./user_topics"; -import * as user_topics_ui from "./user_topics_ui"; -import * as util from "./util"; -import * as views_util from "./views_util"; +import * as buddy_data from "./buddy_data.ts"; +import * as compose_closed_ui from "./compose_closed_ui.ts"; +import * as compose_state from "./compose_state.ts"; +import * as dialog_widget from "./dialog_widget.ts"; +import * as dropdown_widget from "./dropdown_widget.ts"; +import * as hash_util from "./hash_util.ts"; +import {$t_html} from "./i18n.ts"; +import {is_visible, set_visible} from "./inbox_util.ts"; +import * as keydown_util from "./keydown_util.ts"; +import * as left_sidebar_navigation_area from "./left_sidebar_navigation_area.ts"; +import {localstorage} from "./localstorage.ts"; +import * as message_store from "./message_store.ts"; +import type {Message} from "./message_store.ts"; +import * as onboarding_steps from "./onboarding_steps.ts"; +import * as people from "./people.ts"; +import * as stream_color from "./stream_color.ts"; +import * as stream_data from "./stream_data.ts"; +import * as sub_store from "./sub_store.ts"; +import * as unread from "./unread.ts"; +import * as unread_ops from "./unread_ops.ts"; +import {user_settings} from "./user_settings.ts"; +import * as user_status from "./user_status.ts"; +import * as user_topics from "./user_topics.ts"; +import * as user_topics_ui from "./user_topics_ui.ts"; +import * as util from "./util.ts"; +import * as views_util from "./views_util.ts"; type DirectMessageContext = { conversation_key: string; diff --git a/web/src/inbox_util.ts b/web/src/inbox_util.ts index 6d4821f675..df35b24764 100644 --- a/web/src/inbox_util.ts +++ b/web/src/inbox_util.ts @@ -1,7 +1,7 @@ import $ from "jquery"; -import * as stream_color from "./stream_color"; -import * as stream_data from "./stream_data"; +import * as stream_color from "./stream_color.ts"; +import * as stream_data from "./stream_data.ts"; let is_inbox_visible = false; diff --git a/web/src/info_overlay.ts b/web/src/info_overlay.ts index 67c5d90f5a..1f88845758 100644 --- a/web/src/info_overlay.ts +++ b/web/src/info_overlay.ts @@ -4,20 +4,20 @@ import render_keyboard_shortcut from "../templates/keyboard_shortcuts.hbs"; import render_markdown_help from "../templates/markdown_help.hbs"; import render_search_operator from "../templates/search_operators.hbs"; -import * as browser_history from "./browser_history"; -import * as common from "./common"; -import * as components from "./components"; -import type {Toggle} from "./components"; -import {$t, $t_html} from "./i18n"; -import * as keydown_util from "./keydown_util"; -import * as markdown from "./markdown"; -import * as overlays from "./overlays"; -import {page_params} from "./page_params"; -import {postprocess_content} from "./postprocess_content"; -import * as rendered_markdown from "./rendered_markdown"; -import * as scroll_util from "./scroll_util"; -import {current_user} from "./state_data"; -import {user_settings} from "./user_settings"; +import * as browser_history from "./browser_history.ts"; +import * as common from "./common.ts"; +import * as components from "./components.ts"; +import type {Toggle} from "./components.ts"; +import {$t, $t_html} from "./i18n.ts"; +import * as keydown_util from "./keydown_util.ts"; +import * as markdown from "./markdown.ts"; +import * as overlays from "./overlays.ts"; +import {page_params} from "./page_params.ts"; +import {postprocess_content} from "./postprocess_content.ts"; +import * as rendered_markdown from "./rendered_markdown.ts"; +import * as scroll_util from "./scroll_util.ts"; +import {current_user} from "./state_data.ts"; +import {user_settings} from "./user_settings.ts"; // Make it explicit that our toggler is undefined until // set_up_toggler is called. diff --git a/web/src/information_density.ts b/web/src/information_density.ts index e8329c551a..cee4c257f5 100644 --- a/web/src/information_density.ts +++ b/web/src/information_density.ts @@ -1,7 +1,7 @@ import $ from "jquery"; -import {stringify_time} from "./timerender"; -import {user_settings} from "./user_settings"; +import {stringify_time} from "./timerender.ts"; +import {user_settings} from "./user_settings.ts"; // These are all relative-unit values for Source Sans Pro VF, // as opened and inspected in FontForge. diff --git a/web/src/input_pill.ts b/web/src/input_pill.ts index 35dcfc7756..96ae1c4032 100644 --- a/web/src/input_pill.ts +++ b/web/src/input_pill.ts @@ -5,9 +5,9 @@ import assert from "minimalistic-assert"; import render_input_pill from "../templates/input_pill.hbs"; -import * as keydown_util from "./keydown_util"; -import * as ui_util from "./ui_util"; -import * as util from "./util"; +import * as keydown_util from "./keydown_util.ts"; +import * as ui_util from "./ui_util.ts"; +import * as util from "./util.ts"; // See https://zulip.readthedocs.io/en/latest/subsystems/input-pills.html diff --git a/web/src/integration_url_modal.ts b/web/src/integration_url_modal.ts index 5e6c25b3a6..a2e7417024 100644 --- a/web/src/integration_url_modal.ts +++ b/web/src/integration_url_modal.ts @@ -8,14 +8,14 @@ import render_generate_integration_url_config_text_modal from "../templates/sett import render_generate_integration_url_modal from "../templates/settings/generate_integration_url_modal.hbs"; import render_integration_events from "../templates/settings/integration_events.hbs"; -import {show_copied_confirmation} from "./copied_tooltip"; -import * as dialog_widget from "./dialog_widget"; -import * as dropdown_widget from "./dropdown_widget"; -import type {DropdownWidget, Option} from "./dropdown_widget"; -import {$t_html} from "./i18n"; -import {realm} from "./state_data"; -import * as stream_data from "./stream_data"; -import * as util from "./util"; +import {show_copied_confirmation} from "./copied_tooltip.ts"; +import * as dialog_widget from "./dialog_widget.ts"; +import * as dropdown_widget from "./dropdown_widget.ts"; +import type {DropdownWidget, Option} from "./dropdown_widget.ts"; +import {$t_html} from "./i18n.ts"; +import {realm} from "./state_data.ts"; +import * as stream_data from "./stream_data.ts"; +import * as util from "./util.ts"; type ConfigOption = { key: string; diff --git a/web/src/invite.ts b/web/src/invite.ts index 85dd98dda3..56c7304256 100644 --- a/web/src/invite.ts +++ b/web/src/invite.ts @@ -11,29 +11,29 @@ import render_invite_user_modal from "../templates/invite_user_modal.hbs"; import render_invite_tips_banner from "../templates/modal_banner/invite_tips_banner.hbs"; import render_settings_dev_env_email_access from "../templates/settings/dev_env_email_access.hbs"; -import * as channel from "./channel"; -import * as common from "./common"; -import * as components from "./components"; -import * as compose_banner from "./compose_banner"; -import {show_copied_confirmation} from "./copied_tooltip"; -import {csrf_token} from "./csrf"; -import * as dialog_widget from "./dialog_widget"; -import * as email_pill from "./email_pill"; -import {$t, $t_html} from "./i18n"; -import * as input_pill from "./input_pill"; -import * as invite_stream_picker_pill from "./invite_stream_picker_pill"; -import {page_params} from "./page_params"; -import * as peer_data from "./peer_data"; -import * as settings_components from "./settings_components"; -import * as settings_config from "./settings_config"; -import * as settings_data from "./settings_data"; -import {current_user, realm} from "./state_data"; -import * as stream_data from "./stream_data"; -import * as stream_pill from "./stream_pill"; -import * as timerender from "./timerender"; -import type {HTMLSelectOneElement} from "./types"; -import * as ui_report from "./ui_report"; -import * as util from "./util"; +import * as channel from "./channel.ts"; +import * as common from "./common.ts"; +import * as components from "./components.ts"; +import * as compose_banner from "./compose_banner.ts"; +import {show_copied_confirmation} from "./copied_tooltip.ts"; +import {csrf_token} from "./csrf.ts"; +import * as dialog_widget from "./dialog_widget.ts"; +import * as email_pill from "./email_pill.ts"; +import {$t, $t_html} from "./i18n.ts"; +import * as input_pill from "./input_pill.ts"; +import * as invite_stream_picker_pill from "./invite_stream_picker_pill.ts"; +import {page_params} from "./page_params.ts"; +import * as peer_data from "./peer_data.ts"; +import * as settings_components from "./settings_components.ts"; +import * as settings_config from "./settings_config.ts"; +import * as settings_data from "./settings_data.ts"; +import {current_user, realm} from "./state_data.ts"; +import * as stream_data from "./stream_data.ts"; +import * as stream_pill from "./stream_pill.ts"; +import * as timerender from "./timerender.ts"; +import type {HTMLSelectOneElement} from "./types.ts"; +import * as ui_report from "./ui_report.ts"; +import * as util from "./util.ts"; let custom_expiration_time_input = 10; let custom_expiration_time_unit = "days"; diff --git a/web/src/invite_stream_picker_pill.ts b/web/src/invite_stream_picker_pill.ts index 0fa2cf567c..1ebec54ca2 100644 --- a/web/src/invite_stream_picker_pill.ts +++ b/web/src/invite_stream_picker_pill.ts @@ -1,9 +1,9 @@ -import * as input_pill from "./input_pill"; -import {set_up_stream} from "./pill_typeahead"; -import * as stream_data from "./stream_data"; -import * as stream_pill from "./stream_pill"; -import type {StreamPill} from "./stream_pill"; -import type {CombinedPill} from "./typeahead_helper"; +import * as input_pill from "./input_pill.ts"; +import {set_up_stream} from "./pill_typeahead.ts"; +import * as stream_data from "./stream_data.ts"; +import * as stream_pill from "./stream_pill.ts"; +import type {StreamPill} from "./stream_pill.ts"; +import type {CombinedPill} from "./typeahead_helper.ts"; type SetUpPillTypeaheadConfig = { pill_widget: stream_pill.StreamPillWidget; diff --git a/web/src/lazy_set.ts b/web/src/lazy_set.ts index fd1908c0ce..875c2eec6b 100644 --- a/web/src/lazy_set.ts +++ b/web/src/lazy_set.ts @@ -1,4 +1,4 @@ -import * as blueslip from "./blueslip"; +import * as blueslip from "./blueslip.ts"; export class LazySet { private data: diff --git a/web/src/left_sidebar_navigation_area.ts b/web/src/left_sidebar_navigation_area.ts index c7bf676030..2c3f7881ea 100644 --- a/web/src/left_sidebar_navigation_area.ts +++ b/web/src/left_sidebar_navigation_area.ts @@ -1,15 +1,15 @@ import $ from "jquery"; import _ from "lodash"; -import type {Filter} from "./filter"; -import {localstorage} from "./localstorage"; -import {page_params} from "./page_params"; -import * as people from "./people"; -import * as resize from "./resize"; -import * as scheduled_messages from "./scheduled_messages"; -import * as settings_config from "./settings_config"; -import * as ui_util from "./ui_util"; -import * as unread from "./unread"; +import type {Filter} from "./filter.ts"; +import {localstorage} from "./localstorage.ts"; +import {page_params} from "./page_params.ts"; +import * as people from "./people.ts"; +import * as resize from "./resize.ts"; +import * as scheduled_messages from "./scheduled_messages.ts"; +import * as settings_config from "./settings_config.ts"; +import * as ui_util from "./ui_util.ts"; +import * as unread from "./unread.ts"; let last_mention_count = 0; const ls_key = "left_sidebar_views_state"; diff --git a/web/src/left_sidebar_navigation_area_popovers.ts b/web/src/left_sidebar_navigation_area_popovers.ts index 2acd35b9a0..995dbd0738 100644 --- a/web/src/left_sidebar_navigation_area_popovers.ts +++ b/web/src/left_sidebar_navigation_area_popovers.ts @@ -9,17 +9,17 @@ import render_left_sidebar_inbox_popover from "../templates/popovers/left_sideba import render_left_sidebar_recent_view_popover from "../templates/popovers/left_sidebar/left_sidebar_recent_view_popover.hbs"; import render_left_sidebar_starred_messages_popover from "../templates/popovers/left_sidebar/left_sidebar_starred_messages_popover.hbs"; -import * as channel from "./channel"; -import * as drafts from "./drafts"; -import * as popover_menus from "./popover_menus"; -import * as popovers from "./popovers"; -import * as scheduled_messages from "./scheduled_messages"; -import * as settings_config from "./settings_config"; -import * as starred_messages from "./starred_messages"; -import * as starred_messages_ui from "./starred_messages_ui"; -import * as ui_util from "./ui_util"; -import * as unread_ops from "./unread_ops"; -import {user_settings} from "./user_settings"; +import * as channel from "./channel.ts"; +import * as drafts from "./drafts.ts"; +import * as popover_menus from "./popover_menus.ts"; +import * as popovers from "./popovers.ts"; +import * as scheduled_messages from "./scheduled_messages.ts"; +import * as settings_config from "./settings_config.ts"; +import * as starred_messages from "./starred_messages.ts"; +import * as starred_messages_ui from "./starred_messages_ui.ts"; +import * as ui_util from "./ui_util.ts"; +import * as unread_ops from "./unread_ops.ts"; +import {user_settings} from "./user_settings.ts"; function common_click_handlers(): void { $("body").on("click", ".set-home-view", (e) => { diff --git a/web/src/lightbox.ts b/web/src/lightbox.ts index 2fcb8e579d..c6a4078645 100644 --- a/web/src/lightbox.ts +++ b/web/src/lightbox.ts @@ -5,13 +5,13 @@ import type {PanZoom} from "panzoom"; import render_lightbox_overlay from "../templates/lightbox_overlay.hbs"; -import * as blueslip from "./blueslip"; -import * as message_store from "./message_store"; -import * as overlays from "./overlays"; -import * as people from "./people"; -import * as popovers from "./popovers"; -import * as rows from "./rows"; -import * as util from "./util"; +import * as blueslip from "./blueslip.ts"; +import * as message_store from "./message_store.ts"; +import * as overlays from "./overlays.ts"; +import * as people from "./people.ts"; +import * as popovers from "./popovers.ts"; +import * as rows from "./rows.ts"; +import * as util from "./util.ts"; type Payload = { user: string | undefined; diff --git a/web/src/linkifiers.ts b/web/src/linkifiers.ts index 9992d558da..8304419c4a 100644 --- a/web/src/linkifiers.ts +++ b/web/src/linkifiers.ts @@ -1,6 +1,6 @@ import url_template_lib from "url-template"; -import * as blueslip from "./blueslip"; +import * as blueslip from "./blueslip.ts"; type LinkifierMap = Map< RegExp, diff --git a/web/src/list_cursor.ts b/web/src/list_cursor.ts index bb2b8cce9b..a7b2a273cc 100644 --- a/web/src/list_cursor.ts +++ b/web/src/list_cursor.ts @@ -1,7 +1,7 @@ import $ from "jquery"; -import * as blueslip from "./blueslip"; -import * as scroll_util from "./scroll_util"; +import * as blueslip from "./blueslip.ts"; +import * as scroll_util from "./scroll_util.ts"; type List = { scroll_container_selector: string; diff --git a/web/src/list_widget.ts b/web/src/list_widget.ts index 34d98aa9f3..a36ecb356e 100644 --- a/web/src/list_widget.ts +++ b/web/src/list_widget.ts @@ -4,8 +4,8 @@ import assert from "minimalistic-assert"; import render_empty_list_widget_for_list from "../templates/empty_list_widget_for_list.hbs"; import render_empty_list_widget_for_table from "../templates/empty_list_widget_for_table.hbs"; -import * as blueslip from "./blueslip"; -import * as scroll_util from "./scroll_util"; +import * as blueslip from "./blueslip.ts"; +import * as scroll_util from "./scroll_util.ts"; type SortingFunction = (a: T, b: T) => number; diff --git a/web/src/local_message.ts b/web/src/local_message.ts index d991f10cbe..0c61cbb4bd 100644 --- a/web/src/local_message.ts +++ b/web/src/local_message.ts @@ -1,6 +1,6 @@ -import {all_messages_data} from "./all_messages_data"; -import * as blueslip from "./blueslip"; -import type {StateData} from "./state_data"; +import {all_messages_data} from "./all_messages_data.ts"; +import * as blueslip from "./blueslip.ts"; +import type {StateData} from "./state_data.ts"; let max_message_id: number; diff --git a/web/src/localstorage.ts b/web/src/localstorage.ts index 67d7163097..04247a0017 100644 --- a/web/src/localstorage.ts +++ b/web/src/localstorage.ts @@ -1,6 +1,6 @@ import {z} from "zod"; -import * as blueslip from "./blueslip"; +import * as blueslip from "./blueslip.ts"; const formDataSchema = z .object({ diff --git a/web/src/markdown.ts b/web/src/markdown.ts index 424929ac64..9461209e59 100644 --- a/web/src/markdown.ts +++ b/web/src/markdown.ts @@ -4,9 +4,9 @@ import _ from "lodash"; import assert from "minimalistic-assert"; import type {Template} from "url-template"; -import * as fenced_code from "../shared/src/fenced_code"; -import marked from "../third/marked/lib/marked"; -import type {LinkifierMatch, ParseOptions, RegExpOrStub} from "../third/marked/lib/marked"; +import * as fenced_code from "../shared/src/fenced_code.ts"; +import marked from "../third/marked/lib/marked.js"; +import type {LinkifierMatch, ParseOptions, RegExpOrStub} from "../third/marked/lib/marked.js"; // This contains zulip's frontend Markdown implementation; see // docs/subsystems/markdown.md for docs on our Markdown syntax. The other diff --git a/web/src/markdown_config.ts b/web/src/markdown_config.ts index c6444b4505..1b2b716709 100644 --- a/web/src/markdown_config.ts +++ b/web/src/markdown_config.ts @@ -1,12 +1,12 @@ -import * as emoji from "./emoji"; -import * as hash_util from "./hash_util"; -import * as linkifiers from "./linkifiers"; -import type {AbstractMap, MarkdownHelpers} from "./markdown"; -import * as people from "./people"; -import * as stream_data from "./stream_data"; -import type {Stream} from "./sub_store"; -import * as user_groups from "./user_groups"; -import {user_settings} from "./user_settings"; +import * as emoji from "./emoji.ts"; +import * as hash_util from "./hash_util.ts"; +import * as linkifiers from "./linkifiers.ts"; +import type {AbstractMap, MarkdownHelpers} from "./markdown.ts"; +import * as people from "./people.ts"; +import * as stream_data from "./stream_data.ts"; +import type {Stream} from "./sub_store.ts"; +import * as user_groups from "./user_groups.ts"; +import {user_settings} from "./user_settings.ts"; /* This config is in a separate file for partly diff --git a/web/src/message_actions_popover.js b/web/src/message_actions_popover.js index 0d130f4228..957da457b4 100644 --- a/web/src/message_actions_popover.js +++ b/web/src/message_actions_popover.js @@ -4,22 +4,22 @@ import assert from "minimalistic-assert"; import render_message_actions_popover from "../templates/popovers/message_actions_popover.hbs"; -import * as blueslip from "./blueslip"; -import * as compose_reply from "./compose_reply"; -import * as condense from "./condense"; -import {show_copied_confirmation} from "./copied_tooltip"; -import * as emoji_picker from "./emoji_picker"; -import * as message_edit from "./message_edit"; -import * as message_lists from "./message_lists"; -import * as message_viewport from "./message_viewport"; -import * as popover_menus from "./popover_menus"; -import * as popover_menus_data from "./popover_menus_data"; -import * as popovers from "./popovers"; -import * as read_receipts from "./read_receipts"; -import * as rows from "./rows"; -import * as stream_popover from "./stream_popover"; -import {parse_html} from "./ui_util"; -import * as unread_ops from "./unread_ops"; +import * as blueslip from "./blueslip.ts"; +import * as compose_reply from "./compose_reply.ts"; +import * as condense from "./condense.ts"; +import {show_copied_confirmation} from "./copied_tooltip.ts"; +import * as emoji_picker from "./emoji_picker.ts"; +import * as message_edit from "./message_edit.ts"; +import * as message_lists from "./message_lists.ts"; +import * as message_viewport from "./message_viewport.ts"; +import * as popover_menus from "./popover_menus.ts"; +import * as popover_menus_data from "./popover_menus_data.ts"; +import * as popovers from "./popovers.ts"; +import * as read_receipts from "./read_receipts.ts"; +import * as rows from "./rows.ts"; +import * as stream_popover from "./stream_popover.js"; +import {parse_html} from "./ui_util.ts"; +import * as unread_ops from "./unread_ops.ts"; let message_actions_popover_keyboard_toggle = false; diff --git a/web/src/message_edit.ts b/web/src/message_edit.ts index ed7e6107af..78c8fe006b 100644 --- a/web/src/message_edit.ts +++ b/web/src/message_edit.ts @@ -3,7 +3,7 @@ import $ from "jquery"; import assert from "minimalistic-assert"; import {z} from "zod"; -import * as resolved_topic from "../shared/src/resolved_topic"; +import * as resolved_topic from "../shared/src/resolved_topic.ts"; import render_wildcard_mention_not_allowed_error from "../templates/compose_banner/wildcard_mention_not_allowed_error.hbs"; import render_delete_message_modal from "../templates/confirm_dialog/confirm_delete_message.hbs"; import render_confirm_merge_topics_with_rename from "../templates/confirm_dialog/confirm_merge_topics_with_rename.hbs"; @@ -14,49 +14,49 @@ import render_message_moved_widget_body from "../templates/message_moved_widget_ import render_resolve_topic_time_limit_error_modal from "../templates/resolve_topic_time_limit_error_modal.hbs"; import render_topic_edit_form from "../templates/topic_edit_form.hbs"; -import {detached_uploads_api_response_schema} from "./attachments"; -import * as attachments_ui from "./attachments_ui"; -import * as blueslip from "./blueslip"; -import * as channel from "./channel"; -import * as compose_actions from "./compose_actions"; -import * as compose_banner from "./compose_banner"; -import * as compose_call from "./compose_call"; -import * as compose_state from "./compose_state"; -import * as compose_tooltips from "./compose_tooltips"; -import * as compose_ui from "./compose_ui"; -import * as compose_validate from "./compose_validate"; -import * as composebox_typeahead from "./composebox_typeahead"; -import * as condense from "./condense"; -import * as confirm_dialog from "./confirm_dialog"; -import {show_copied_confirmation} from "./copied_tooltip"; -import * as dialog_widget from "./dialog_widget"; -import * as echo from "./echo"; -import * as feedback_widget from "./feedback_widget"; -import * as giphy_state from "./giphy_state"; -import * as hash_util from "./hash_util"; -import {$t, $t_html} from "./i18n"; -import * as keydown_util from "./keydown_util"; -import * as loading from "./loading"; -import * as markdown from "./markdown"; -import * as message_lists from "./message_lists"; -import * as message_live_update from "./message_live_update"; -import * as message_store from "./message_store"; -import type {Message} from "./message_store"; -import * as message_viewport from "./message_viewport"; -import * as onboarding_steps from "./onboarding_steps"; -import * as people from "./people"; -import * as resize from "./resize"; -import * as rows from "./rows"; -import * as settings_data from "./settings_data"; -import {current_user, realm} from "./state_data"; -import * as stream_data from "./stream_data"; -import * as stream_topic_history from "./stream_topic_history"; -import * as sub_store from "./sub_store"; -import * as timerender from "./timerender"; -import * as ui_report from "./ui_report"; -import * as upload from "./upload"; -import {the} from "./util"; -import * as util from "./util"; +import {detached_uploads_api_response_schema} from "./attachments.ts"; +import * as attachments_ui from "./attachments_ui.ts"; +import * as blueslip from "./blueslip.ts"; +import * as channel from "./channel.ts"; +import * as compose_actions from "./compose_actions.ts"; +import * as compose_banner from "./compose_banner.ts"; +import * as compose_call from "./compose_call.ts"; +import * as compose_state from "./compose_state.ts"; +import * as compose_tooltips from "./compose_tooltips.ts"; +import * as compose_ui from "./compose_ui.ts"; +import * as compose_validate from "./compose_validate.ts"; +import * as composebox_typeahead from "./composebox_typeahead.ts"; +import * as condense from "./condense.ts"; +import * as confirm_dialog from "./confirm_dialog.ts"; +import {show_copied_confirmation} from "./copied_tooltip.ts"; +import * as dialog_widget from "./dialog_widget.ts"; +import * as echo from "./echo.ts"; +import * as feedback_widget from "./feedback_widget.ts"; +import * as giphy_state from "./giphy_state.ts"; +import * as hash_util from "./hash_util.ts"; +import {$t, $t_html} from "./i18n.ts"; +import * as keydown_util from "./keydown_util.ts"; +import * as loading from "./loading.ts"; +import * as markdown from "./markdown.ts"; +import * as message_lists from "./message_lists.ts"; +import * as message_live_update from "./message_live_update.ts"; +import * as message_store from "./message_store.ts"; +import type {Message} from "./message_store.ts"; +import * as message_viewport from "./message_viewport.ts"; +import * as onboarding_steps from "./onboarding_steps.ts"; +import * as people from "./people.ts"; +import * as resize from "./resize.ts"; +import * as rows from "./rows.ts"; +import * as settings_data from "./settings_data.ts"; +import {current_user, realm} from "./state_data.ts"; +import * as stream_data from "./stream_data.ts"; +import * as stream_topic_history from "./stream_topic_history.ts"; +import * as sub_store from "./sub_store.ts"; +import * as timerender from "./timerender.ts"; +import * as ui_report from "./ui_report.ts"; +import * as upload from "./upload.ts"; +import {the} from "./util.ts"; +import * as util from "./util.ts"; // Stores the message ID of the message being edited, and the // textarea element which has the modified content. diff --git a/web/src/message_edit_history.ts b/web/src/message_edit_history.ts index 7cce8e842d..9c0c704f88 100644 --- a/web/src/message_edit_history.ts +++ b/web/src/message_edit_history.ts @@ -5,25 +5,25 @@ import {z} from "zod"; import render_message_edit_history from "../templates/message_edit_history.hbs"; import render_message_history_overlay from "../templates/message_history_overlay.hbs"; -import {exit_overlay} from "./browser_history"; -import * as channel from "./channel"; -import {$t, $t_html} from "./i18n"; -import * as loading from "./loading"; -import * as message_lists from "./message_lists"; -import type {Message} from "./message_store"; -import * as messages_overlay_ui from "./messages_overlay_ui"; -import * as overlays from "./overlays"; -import {page_params} from "./page_params"; -import * as people from "./people"; -import * as rendered_markdown from "./rendered_markdown"; -import * as rows from "./rows"; -import * as spectators from "./spectators"; -import {realm} from "./state_data"; -import {get_recipient_bar_color} from "./stream_color"; -import {get_color} from "./stream_data"; -import * as sub_store from "./sub_store"; -import * as timerender from "./timerender"; -import * as ui_report from "./ui_report"; +import {exit_overlay} from "./browser_history.ts"; +import * as channel from "./channel.ts"; +import {$t, $t_html} from "./i18n.ts"; +import * as loading from "./loading.ts"; +import * as message_lists from "./message_lists.ts"; +import type {Message} from "./message_store.ts"; +import * as messages_overlay_ui from "./messages_overlay_ui.ts"; +import * as overlays from "./overlays.ts"; +import {page_params} from "./page_params.ts"; +import * as people from "./people.ts"; +import * as rendered_markdown from "./rendered_markdown.ts"; +import * as rows from "./rows.ts"; +import * as spectators from "./spectators.ts"; +import {realm} from "./state_data.ts"; +import {get_recipient_bar_color} from "./stream_color.ts"; +import {get_color} from "./stream_data.ts"; +import * as sub_store from "./sub_store.ts"; +import * as timerender from "./timerender.ts"; +import * as ui_report from "./ui_report.ts"; type EditHistoryEntry = { edited_at_time: string; diff --git a/web/src/message_events.js b/web/src/message_events.js index c2c19ccbdb..0b60e2463b 100644 --- a/web/src/message_events.js +++ b/web/src/message_events.js @@ -2,42 +2,42 @@ import $ from "jquery"; import _ from "lodash"; import assert from "minimalistic-assert"; -import * as activity from "./activity"; -import * as alert_words from "./alert_words"; -import * as channel from "./channel"; -import * as compose_fade from "./compose_fade"; -import * as compose_notifications from "./compose_notifications"; -import * as compose_recipient from "./compose_recipient"; -import * as compose_state from "./compose_state"; -import * as compose_validate from "./compose_validate"; -import * as direct_message_group_data from "./direct_message_group_data"; -import * as drafts from "./drafts"; -import * as echo from "./echo"; -import * as message_edit from "./message_edit"; -import * as message_edit_history from "./message_edit_history"; -import * as message_events_util from "./message_events_util"; -import * as message_helper from "./message_helper"; -import * as message_list_data_cache from "./message_list_data_cache"; -import * as message_lists from "./message_lists"; -import * as message_notifications from "./message_notifications"; -import * as message_parser from "./message_parser"; -import * as message_store from "./message_store"; -import * as message_util from "./message_util"; -import * as message_view from "./message_view"; -import * as narrow_state from "./narrow_state"; -import * as pm_list from "./pm_list"; -import * as recent_senders from "./recent_senders"; -import * as recent_view_ui from "./recent_view_ui"; -import * as recent_view_util from "./recent_view_util"; -import * as starred_messages from "./starred_messages"; -import * as starred_messages_ui from "./starred_messages_ui"; -import {realm} from "./state_data"; -import * as stream_list from "./stream_list"; -import * as stream_topic_history from "./stream_topic_history"; -import * as sub_store from "./sub_store"; -import * as unread from "./unread"; -import * as unread_ui from "./unread_ui"; -import * as util from "./util"; +import * as activity from "./activity.ts"; +import * as alert_words from "./alert_words.ts"; +import * as channel from "./channel.ts"; +import * as compose_fade from "./compose_fade.ts"; +import * as compose_notifications from "./compose_notifications.ts"; +import * as compose_recipient from "./compose_recipient.ts"; +import * as compose_state from "./compose_state.ts"; +import * as compose_validate from "./compose_validate.ts"; +import * as direct_message_group_data from "./direct_message_group_data.ts"; +import * as drafts from "./drafts.ts"; +import * as echo from "./echo.ts"; +import * as message_edit from "./message_edit.ts"; +import * as message_edit_history from "./message_edit_history.ts"; +import * as message_events_util from "./message_events_util.ts"; +import * as message_helper from "./message_helper.ts"; +import * as message_list_data_cache from "./message_list_data_cache.ts"; +import * as message_lists from "./message_lists.ts"; +import * as message_notifications from "./message_notifications.ts"; +import * as message_parser from "./message_parser.ts"; +import * as message_store from "./message_store.ts"; +import * as message_util from "./message_util.ts"; +import * as message_view from "./message_view.ts"; +import * as narrow_state from "./narrow_state.ts"; +import * as pm_list from "./pm_list.ts"; +import * as recent_senders from "./recent_senders.ts"; +import * as recent_view_ui from "./recent_view_ui.ts"; +import * as recent_view_util from "./recent_view_util.ts"; +import * as starred_messages from "./starred_messages.ts"; +import * as starred_messages_ui from "./starred_messages_ui.ts"; +import {realm} from "./state_data.ts"; +import * as stream_list from "./stream_list.ts"; +import * as stream_topic_history from "./stream_topic_history.ts"; +import * as sub_store from "./sub_store.ts"; +import * as unread from "./unread.ts"; +import * as unread_ui from "./unread_ui.ts"; +import * as util from "./util.ts"; function filter_has_term_type(filter, term_type) { return ( diff --git a/web/src/message_events_util.ts b/web/src/message_events_util.ts index 766d30529b..47acc28a7a 100644 --- a/web/src/message_events_util.ts +++ b/web/src/message_events_util.ts @@ -1,15 +1,15 @@ import {z} from "zod"; -import * as blueslip from "./blueslip"; -import * as channel from "./channel"; -import * as compose_notifications from "./compose_notifications"; -import type {MessageList, RenderInfo} from "./message_list"; -import * as message_lists from "./message_lists"; -import * as message_store from "./message_store"; -import type {Message} from "./message_store"; -import * as narrow_state from "./narrow_state"; -import * as unread_ops from "./unread_ops"; -import * as util from "./util"; +import * as blueslip from "./blueslip.ts"; +import * as channel from "./channel.ts"; +import * as compose_notifications from "./compose_notifications.ts"; +import type {MessageList, RenderInfo} from "./message_list.ts"; +import * as message_lists from "./message_lists.ts"; +import * as message_store from "./message_store.ts"; +import type {Message} from "./message_store.ts"; +import * as narrow_state from "./narrow_state.ts"; +import * as unread_ops from "./unread_ops.ts"; +import * as util from "./util.ts"; const msg_match_narrow_api_response_schema = z.object({ messages: z.record( diff --git a/web/src/message_feed_loading.ts b/web/src/message_feed_loading.ts index 3000cefe86..d7c88920e0 100644 --- a/web/src/message_feed_loading.ts +++ b/web/src/message_feed_loading.ts @@ -1,6 +1,6 @@ import $ from "jquery"; -import * as loading from "./loading"; +import * as loading from "./loading.ts"; let loading_older_messages_indicator_showing = false; let loading_newer_messages_indicator_showing = false; diff --git a/web/src/message_feed_top_notices.ts b/web/src/message_feed_top_notices.ts index cefb413461..c8f8bfa342 100644 --- a/web/src/message_feed_top_notices.ts +++ b/web/src/message_feed_top_notices.ts @@ -2,12 +2,12 @@ import $ from "jquery"; import _ from "lodash"; import assert from "minimalistic-assert"; -import * as hash_util from "./hash_util"; -import type {MessageList} from "./message_list"; -import * as message_lists from "./message_lists"; -import * as narrow_banner from "./narrow_banner"; -import * as narrow_state from "./narrow_state"; -import * as people from "./people"; +import * as hash_util from "./hash_util.ts"; +import type {MessageList} from "./message_list.ts"; +import * as message_lists from "./message_lists.ts"; +import * as narrow_banner from "./narrow_banner.ts"; +import * as narrow_state from "./narrow_state.ts"; +import * as people from "./people.ts"; function show_history_limit_notice(): void { $(".top-messages-logo").hide(); diff --git a/web/src/message_fetch.ts b/web/src/message_fetch.ts index 17e310ac57..8266bd69fa 100644 --- a/web/src/message_fetch.ts +++ b/web/src/message_fetch.ts @@ -2,30 +2,30 @@ import $ from "jquery"; import assert from "minimalistic-assert"; import {z} from "zod"; -import {all_messages_data} from "./all_messages_data"; -import * as blueslip from "./blueslip"; -import * as channel from "./channel"; -import * as compose_closed_ui from "./compose_closed_ui"; -import * as compose_recipient from "./compose_recipient"; -import * as direct_message_group_data from "./direct_message_group_data"; -import {Filter} from "./filter"; -import * as message_feed_loading from "./message_feed_loading"; -import * as message_feed_top_notices from "./message_feed_top_notices"; -import * as message_helper from "./message_helper"; -import type {MessageList} from "./message_list"; -import type {MessageListData} from "./message_list_data"; -import * as message_lists from "./message_lists"; -import {raw_message_schema} from "./message_store"; -import * as message_util from "./message_util"; -import * as narrow_banner from "./narrow_banner"; -import {page_params} from "./page_params"; -import * as people from "./people"; -import * as recent_view_ui from "./recent_view_ui"; -import type {NarrowTerm} from "./state_data"; -import {narrow_term_schema} from "./state_data"; -import * as stream_data from "./stream_data"; -import * as stream_list from "./stream_list"; -import * as ui_report from "./ui_report"; +import {all_messages_data} from "./all_messages_data.ts"; +import * as blueslip from "./blueslip.ts"; +import * as channel from "./channel.ts"; +import * as compose_closed_ui from "./compose_closed_ui.ts"; +import * as compose_recipient from "./compose_recipient.ts"; +import * as direct_message_group_data from "./direct_message_group_data.ts"; +import {Filter} from "./filter.ts"; +import * as message_feed_loading from "./message_feed_loading.ts"; +import * as message_feed_top_notices from "./message_feed_top_notices.ts"; +import * as message_helper from "./message_helper.ts"; +import type {MessageList} from "./message_list.ts"; +import type {MessageListData} from "./message_list_data.ts"; +import * as message_lists from "./message_lists.ts"; +import {raw_message_schema} from "./message_store.ts"; +import * as message_util from "./message_util.ts"; +import * as narrow_banner from "./narrow_banner.ts"; +import {page_params} from "./page_params.ts"; +import * as people from "./people.ts"; +import * as recent_view_ui from "./recent_view_ui.ts"; +import type {NarrowTerm} from "./state_data.ts"; +import {narrow_term_schema} from "./state_data.ts"; +import * as stream_data from "./stream_data.ts"; +import * as stream_list from "./stream_list.ts"; +import * as ui_report from "./ui_report.ts"; const response_schema = z.object({ anchor: z.number(), diff --git a/web/src/message_flags.ts b/web/src/message_flags.ts index 414463f249..db8717b640 100644 --- a/web/src/message_flags.ts +++ b/web/src/message_flags.ts @@ -2,9 +2,9 @@ import type {DebouncedFunc} from "lodash"; import _ from "lodash"; import {z} from "zod"; -import * as channel from "./channel"; -import type {Message} from "./message_store"; -import * as starred_messages from "./starred_messages"; +import * as channel from "./channel.ts"; +import type {Message} from "./message_store.ts"; +import * as starred_messages from "./starred_messages.ts"; export function send_flag_update_for_messages(msg_ids: number[], flag: string, op: string): void { void channel.post({ diff --git a/web/src/message_helper.ts b/web/src/message_helper.ts index ca11347306..6d65314f26 100644 --- a/web/src/message_helper.ts +++ b/web/src/message_helper.ts @@ -1,18 +1,18 @@ import _ from "lodash"; import assert from "minimalistic-assert"; -import * as alert_words from "./alert_words"; -import * as message_store from "./message_store"; -import type {Message, RawMessage} from "./message_store"; -import * as message_user_ids from "./message_user_ids"; -import * as people from "./people"; -import * as pm_conversations from "./pm_conversations"; -import * as reactions from "./reactions"; -import * as recent_senders from "./recent_senders"; -import * as stream_data from "./stream_data"; -import * as stream_topic_history from "./stream_topic_history"; -import * as user_status from "./user_status"; -import * as util from "./util"; +import * as alert_words from "./alert_words.ts"; +import * as message_store from "./message_store.ts"; +import type {Message, RawMessage} from "./message_store.ts"; +import * as message_user_ids from "./message_user_ids.ts"; +import * as people from "./people.ts"; +import * as pm_conversations from "./pm_conversations.ts"; +import * as reactions from "./reactions.ts"; +import * as recent_senders from "./recent_senders.ts"; +import * as stream_data from "./stream_data.ts"; +import * as stream_topic_history from "./stream_topic_history.ts"; +import * as user_status from "./user_status.ts"; +import * as util from "./util.ts"; export function process_new_message(raw_message: RawMessage, deliver_locally = false): Message { // Call this function when processing a new message. After diff --git a/web/src/message_list.ts b/web/src/message_list.ts index 6b62a7a545..5a1f6df830 100644 --- a/web/src/message_list.ts +++ b/web/src/message_list.ts @@ -2,21 +2,21 @@ import autosize from "autosize"; import $ from "jquery"; import assert from "minimalistic-assert"; -import * as activity_ui from "./activity_ui"; -import * as blueslip from "./blueslip"; -import * as compose_tooltips from "./compose_tooltips"; -import type {MessageListData} from "./message_list_data"; -import * as message_list_tooltips from "./message_list_tooltips"; -import {MessageListView} from "./message_list_view"; -import * as message_lists from "./message_lists"; -import type {Message} from "./message_store"; -import * as narrow_banner from "./narrow_banner"; -import * as narrow_state from "./narrow_state"; -import {page_params} from "./page_params"; -import {web_mark_read_on_scroll_policy_values} from "./settings_config"; -import * as stream_data from "./stream_data"; -import * as unread from "./unread"; -import {user_settings} from "./user_settings"; +import * as activity_ui from "./activity_ui.ts"; +import * as blueslip from "./blueslip.ts"; +import * as compose_tooltips from "./compose_tooltips.ts"; +import type {MessageListData} from "./message_list_data.ts"; +import * as message_list_tooltips from "./message_list_tooltips.ts"; +import {MessageListView} from "./message_list_view.ts"; +import * as message_lists from "./message_lists.ts"; +import type {Message} from "./message_store.ts"; +import * as narrow_banner from "./narrow_banner.ts"; +import * as narrow_state from "./narrow_state.ts"; +import {page_params} from "./page_params.ts"; +import {web_mark_read_on_scroll_policy_values} from "./settings_config.ts"; +import * as stream_data from "./stream_data.ts"; +import * as unread from "./unread.ts"; +import {user_settings} from "./user_settings.ts"; export type RenderInfo = {need_user_to_scroll: boolean}; diff --git a/web/src/message_list_data.ts b/web/src/message_list_data.ts index d0f0220ac3..494bd074d9 100644 --- a/web/src/message_list_data.ts +++ b/web/src/message_list_data.ts @@ -1,13 +1,13 @@ import assert from "minimalistic-assert"; -import * as blueslip from "./blueslip"; -import {FetchStatus} from "./fetch_status"; -import type {Filter} from "./filter"; -import type {Message} from "./message_store"; -import * as muted_users from "./muted_users"; -import {current_user} from "./state_data"; -import * as user_topics from "./user_topics"; -import * as util from "./util"; +import * as blueslip from "./blueslip.ts"; +import {FetchStatus} from "./fetch_status.ts"; +import type {Filter} from "./filter.ts"; +import type {Message} from "./message_store.ts"; +import * as muted_users from "./muted_users.ts"; +import {current_user} from "./state_data.ts"; +import * as user_topics from "./user_topics.ts"; +import * as util from "./util.ts"; export class MessageListData { // The Filter object defines which messages match the narrow, diff --git a/web/src/message_list_data_cache.ts b/web/src/message_list_data_cache.ts index c2d77a0684..54e1baf71a 100644 --- a/web/src/message_list_data_cache.ts +++ b/web/src/message_list_data_cache.ts @@ -1,6 +1,6 @@ -import * as all_messages_data from "./all_messages_data"; -import type {Filter} from "./filter"; -import type {MessageListData} from "./message_list_data"; +import * as all_messages_data from "./all_messages_data.ts"; +import type {Filter} from "./filter.ts"; +import type {MessageListData} from "./message_list_data.ts"; // LRU cache for message list data. // diff --git a/web/src/message_list_hover.ts b/web/src/message_list_hover.ts index cf48493b7f..1bf6100e85 100644 --- a/web/src/message_list_hover.ts +++ b/web/src/message_list_hover.ts @@ -3,11 +3,11 @@ import assert from "minimalistic-assert"; import render_edit_content_button from "../templates/edit_content_button.hbs"; -import * as message_edit from "./message_edit"; -import * as message_lists from "./message_lists"; -import * as rows from "./rows"; -import * as thumbnail from "./thumbnail"; -import {user_settings} from "./user_settings"; +import * as message_edit from "./message_edit.ts"; +import * as message_lists from "./message_lists.ts"; +import * as rows from "./rows.ts"; +import * as thumbnail from "./thumbnail.ts"; +import {user_settings} from "./user_settings.ts"; let $current_message_hover: JQuery | undefined; export function message_unhover(): void { diff --git a/web/src/message_list_tooltips.ts b/web/src/message_list_tooltips.ts index f67a4a959b..7d82867cce 100644 --- a/web/src/message_list_tooltips.ts +++ b/web/src/message_list_tooltips.ts @@ -6,20 +6,20 @@ import render_message_edit_notice_tooltip from "../templates/message_edit_notice import render_message_inline_image_tooltip from "../templates/message_inline_image_tooltip.hbs"; import render_narrow_tooltip from "../templates/narrow_tooltip.hbs"; -import {$t} from "./i18n"; -import * as message_lists from "./message_lists"; -import type {Message} from "./message_store"; -import * as popover_menus from "./popover_menus"; -import * as reactions from "./reactions"; -import * as rows from "./rows"; -import {realm} from "./state_data"; -import * as timerender from "./timerender"; +import {$t} from "./i18n.ts"; +import * as message_lists from "./message_lists.ts"; +import type {Message} from "./message_store.ts"; +import * as popover_menus from "./popover_menus.ts"; +import * as reactions from "./reactions.ts"; +import * as rows from "./rows.ts"; +import {realm} from "./state_data.ts"; +import * as timerender from "./timerender.ts"; import { INTERACTIVE_HOVER_DELAY, LONG_HOVER_DELAY, topic_visibility_policy_tooltip_props, -} from "./tippyjs"; -import {parse_html} from "./ui_util"; +} from "./tippyjs.ts"; +import {parse_html} from "./ui_util.ts"; type Config = { attributes: boolean; diff --git a/web/src/message_list_view.ts b/web/src/message_list_view.ts index c72e469e20..4230016efa 100644 --- a/web/src/message_list_view.ts +++ b/web/src/message_list_view.ts @@ -3,7 +3,7 @@ import $ from "jquery"; import _ from "lodash"; import assert from "minimalistic-assert"; -import * as resolved_topic from "../shared/src/resolved_topic"; +import * as resolved_topic from "../shared/src/resolved_topic.ts"; import render_bookend from "../templates/bookend.hbs"; import render_login_to_view_image_button from "../templates/login_to_view_image_button.hbs"; import render_message_group from "../templates/message_group.hbs"; @@ -11,40 +11,40 @@ import render_message_list from "../templates/message_list.hbs"; import render_recipient_row from "../templates/recipient_row.hbs"; import render_single_message from "../templates/single_message.hbs"; -import * as activity from "./activity"; -import * as blueslip from "./blueslip"; -import * as compose_fade from "./compose_fade"; -import * as compose_state from "./compose_state"; -import * as condense from "./condense"; -import * as hash_util from "./hash_util"; -import {$t} from "./i18n"; -import * as message_edit from "./message_edit"; -import type {MessageList} from "./message_list"; -import * as message_list_tooltips from "./message_list_tooltips"; -import * as message_lists from "./message_lists"; -import * as message_store from "./message_store"; -import type {Message} from "./message_store"; -import * as message_viewport from "./message_viewport"; -import type {MessageViewportInfo} from "./message_viewport"; -import * as muted_users from "./muted_users"; -import * as narrow_state from "./narrow_state"; -import {page_params} from "./page_params"; -import * as people from "./people"; -import * as popovers from "./popovers"; -import * as reactions from "./reactions"; -import * as rendered_markdown from "./rendered_markdown"; -import * as rows from "./rows"; -import * as sidebar_ui from "./sidebar_ui"; -import * as stream_color from "./stream_color"; -import * as stream_data from "./stream_data"; -import * as sub_store from "./sub_store"; -import * as submessage from "./submessage"; -import {is_same_day} from "./time_zone_util"; -import * as timerender from "./timerender"; -import type {TopicLink} from "./types"; -import * as user_topics from "./user_topics"; -import type {AllVisibilityPolicies} from "./user_topics"; -import * as util from "./util"; +import * as activity from "./activity.ts"; +import * as blueslip from "./blueslip.ts"; +import * as compose_fade from "./compose_fade.ts"; +import * as compose_state from "./compose_state.ts"; +import * as condense from "./condense.ts"; +import * as hash_util from "./hash_util.ts"; +import {$t} from "./i18n.ts"; +import * as message_edit from "./message_edit.ts"; +import type {MessageList} from "./message_list.ts"; +import * as message_list_tooltips from "./message_list_tooltips.ts"; +import * as message_lists from "./message_lists.ts"; +import * as message_store from "./message_store.ts"; +import type {Message} from "./message_store.ts"; +import * as message_viewport from "./message_viewport.ts"; +import type {MessageViewportInfo} from "./message_viewport.ts"; +import * as muted_users from "./muted_users.ts"; +import * as narrow_state from "./narrow_state.ts"; +import {page_params} from "./page_params.ts"; +import * as people from "./people.ts"; +import * as popovers from "./popovers.ts"; +import * as reactions from "./reactions.ts"; +import * as rendered_markdown from "./rendered_markdown.ts"; +import * as rows from "./rows.ts"; +import * as sidebar_ui from "./sidebar_ui.ts"; +import * as stream_color from "./stream_color.ts"; +import * as stream_data from "./stream_data.ts"; +import * as sub_store from "./sub_store.ts"; +import * as submessage from "./submessage.ts"; +import {is_same_day} from "./time_zone_util.ts"; +import * as timerender from "./timerender.ts"; +import type {TopicLink} from "./types.ts"; +import * as user_topics from "./user_topics.ts"; +import type {AllVisibilityPolicies} from "./user_topics.ts"; +import * as util from "./util.ts"; export type MessageContainer = { background_color?: string; diff --git a/web/src/message_lists.ts b/web/src/message_lists.ts index a8c8f8c69e..5f58b3f42f 100644 --- a/web/src/message_lists.ts +++ b/web/src/message_lists.ts @@ -1,10 +1,10 @@ import $ from "jquery"; -import * as inbox_util from "./inbox_util"; -import type {MessageList} from "./message_list"; -import type {MessageListData} from "./message_list_data"; -import * as message_list_data_cache from "./message_list_data_cache"; -import * as ui_util from "./ui_util"; +import * as inbox_util from "./inbox_util.ts"; +import type {MessageList} from "./message_list.ts"; +import type {MessageListData} from "./message_list_data.ts"; +import * as message_list_data_cache from "./message_list_data_cache.ts"; +import * as ui_util from "./ui_util.ts"; export let current: MessageList | undefined; export const rendered_message_lists = new Map(); diff --git a/web/src/message_live_update.ts b/web/src/message_live_update.ts index 25c7abd713..d27f53d5eb 100644 --- a/web/src/message_live_update.ts +++ b/web/src/message_live_update.ts @@ -1,6 +1,6 @@ -import * as message_lists from "./message_lists"; -import * as message_store from "./message_store"; -import type {UserStatusEmojiInfo} from "./user_status"; +import * as message_lists from "./message_lists.ts"; +import * as message_store from "./message_store.ts"; +import type {UserStatusEmojiInfo} from "./user_status.ts"; export function rerender_messages_view(): void { for (const list of message_lists.all_rendered_message_lists()) { diff --git a/web/src/message_notifications.ts b/web/src/message_notifications.ts index e35d197020..52cfd1cfd8 100644 --- a/web/src/message_notifications.ts +++ b/web/src/message_notifications.ts @@ -1,20 +1,20 @@ import $ from "jquery"; -import * as alert_words from "./alert_words"; -import * as blueslip from "./blueslip"; -import * as desktop_notifications from "./desktop_notifications"; -import type {ElectronBridgeNotification} from "./desktop_notifications"; -import {$t} from "./i18n"; -import * as message_parser from "./message_parser"; -import type {Message} from "./message_store"; -import * as message_view from "./message_view"; -import * as people from "./people"; -import * as spoilers from "./spoilers"; -import * as stream_data from "./stream_data"; -import * as ui_util from "./ui_util"; -import {user_settings} from "./user_settings"; -import * as user_topics from "./user_topics"; -import * as util from "./util"; +import * as alert_words from "./alert_words.ts"; +import * as blueslip from "./blueslip.ts"; +import * as desktop_notifications from "./desktop_notifications.ts"; +import type {ElectronBridgeNotification} from "./desktop_notifications.ts"; +import {$t} from "./i18n.ts"; +import * as message_parser from "./message_parser.ts"; +import type {Message} from "./message_store.ts"; +import * as message_view from "./message_view.ts"; +import * as people from "./people.ts"; +import * as spoilers from "./spoilers.ts"; +import * as stream_data from "./stream_data.ts"; +import * as ui_util from "./ui_util.ts"; +import {user_settings} from "./user_settings.ts"; +import * as user_topics from "./user_topics.ts"; +import * as util from "./util.ts"; type TestNotificationMessage = { id: number; diff --git a/web/src/message_parser.ts b/web/src/message_parser.ts index acf0cffab3..e53a0d552d 100644 --- a/web/src/message_parser.ts +++ b/web/src/message_parser.ts @@ -1,7 +1,7 @@ // We only use jquery for parsing. import $ from "jquery"; -import type {Message} from "./message_store"; +import type {Message} from "./message_store.ts"; // We need to check if the message content contains the specified HTML // elements. We wrap the message.content in a
; this is diff --git a/web/src/message_scroll.js b/web/src/message_scroll.js index 8057faaf98..0c95fd7211 100644 --- a/web/src/message_scroll.js +++ b/web/src/message_scroll.js @@ -1,15 +1,15 @@ import $ from "jquery"; import _ from "lodash"; -import * as compose_banner from "./compose_banner"; -import * as message_fetch from "./message_fetch"; -import * as message_lists from "./message_lists"; -import * as message_scroll_state from "./message_scroll_state"; -import * as message_viewport from "./message_viewport"; -import * as narrow_state from "./narrow_state"; -import * as unread from "./unread"; -import * as unread_ops from "./unread_ops"; -import * as unread_ui from "./unread_ui"; +import * as compose_banner from "./compose_banner.ts"; +import * as message_fetch from "./message_fetch.ts"; +import * as message_lists from "./message_lists.ts"; +import * as message_scroll_state from "./message_scroll_state.ts"; +import * as message_viewport from "./message_viewport.ts"; +import * as narrow_state from "./narrow_state.ts"; +import * as unread from "./unread.ts"; +import * as unread_ops from "./unread_ops.ts"; +import * as unread_ui from "./unread_ui.ts"; let hide_scroll_to_bottom_timer; export function hide_scroll_to_bottom() { diff --git a/web/src/message_store.ts b/web/src/message_store.ts index 7fc4a214cf..fa93c329b3 100644 --- a/web/src/message_store.ts +++ b/web/src/message_store.ts @@ -1,11 +1,11 @@ import _ from "lodash"; import {z} from "zod"; -import * as blueslip from "./blueslip"; -import * as people from "./people"; -import {topic_link_schema} from "./types"; -import type {UserStatusEmojiInfo} from "./user_status"; -import * as util from "./util"; +import * as blueslip from "./blueslip.ts"; +import * as people from "./people.ts"; +import {topic_link_schema} from "./types.ts"; +import type {UserStatusEmojiInfo} from "./user_status.ts"; +import * as util from "./util.ts"; const stored_messages = new Map(); diff --git a/web/src/message_util.ts b/web/src/message_util.ts index dff7b81c52..2e2330493b 100644 --- a/web/src/message_util.ts +++ b/web/src/message_util.ts @@ -1,15 +1,15 @@ import assert from "minimalistic-assert"; -import {all_messages_data} from "./all_messages_data"; -import type {MessageList, RenderInfo} from "./message_list"; -import type {MessageListData} from "./message_list_data"; -import * as message_lists from "./message_lists"; -import * as message_store from "./message_store"; -import type {Message} from "./message_store"; -import * as people from "./people"; -import * as pm_conversations from "./pm_conversations"; -import * as unread from "./unread"; -import * as unread_ui from "./unread_ui"; +import {all_messages_data} from "./all_messages_data.ts"; +import type {MessageList, RenderInfo} from "./message_list.ts"; +import type {MessageListData} from "./message_list_data.ts"; +import * as message_lists from "./message_lists.ts"; +import * as message_store from "./message_store.ts"; +import type {Message} from "./message_store.ts"; +import * as people from "./people.ts"; +import * as pm_conversations from "./pm_conversations.ts"; +import * as unread from "./unread.ts"; +import * as unread_ui from "./unread_ui.ts"; type DirectMessagePermissionHints = { is_known_empty_conversation: boolean; diff --git a/web/src/message_view.ts b/web/src/message_view.ts index 5b1626f841..372bfccece 100644 --- a/web/src/message_view.ts +++ b/web/src/message_view.ts @@ -4,66 +4,66 @@ import $ from "jquery"; import assert from "minimalistic-assert"; import {z} from "zod"; -import * as activity_ui from "./activity_ui"; -import {all_messages_data} from "./all_messages_data"; -import * as blueslip from "./blueslip"; -import * as browser_history from "./browser_history"; -import * as channel from "./channel"; -import * as compose_actions from "./compose_actions"; -import * as compose_banner from "./compose_banner"; -import * as compose_closed_ui from "./compose_closed_ui"; -import * as compose_notifications from "./compose_notifications"; -import * as compose_recipient from "./compose_recipient"; -import * as compose_state from "./compose_state"; -import * as condense from "./condense"; -import * as feedback_widget from "./feedback_widget"; -import type {FetchStatus} from "./fetch_status"; -import {Filter} from "./filter"; -import * as hash_parser from "./hash_parser"; -import * as hash_util from "./hash_util"; -import {$t} from "./i18n"; -import * as inbox_ui from "./inbox_ui"; -import * as inbox_util from "./inbox_util"; -import * as left_sidebar_navigation_area from "./left_sidebar_navigation_area"; -import * as message_edit from "./message_edit"; -import * as message_feed_loading from "./message_feed_loading"; -import * as message_feed_top_notices from "./message_feed_top_notices"; -import * as message_fetch from "./message_fetch"; -import * as message_helper from "./message_helper"; -import type {MessageList, SelectIdOpts} from "./message_list"; -import * as message_list from "./message_list"; -import {MessageListData} from "./message_list_data"; -import * as message_list_data_cache from "./message_list_data_cache"; -import * as message_lists from "./message_lists"; -import * as message_scroll_state from "./message_scroll_state"; -import {raw_message_schema} from "./message_store"; -import * as message_store from "./message_store"; -import * as message_view_header from "./message_view_header"; -import * as message_viewport from "./message_viewport"; -import * as narrow_banner from "./narrow_banner"; -import * as narrow_history from "./narrow_history"; -import * as narrow_state from "./narrow_state"; -import * as narrow_title from "./narrow_title"; -import {page_params} from "./page_params"; -import * as people from "./people"; -import * as pm_list from "./pm_list"; -import * as recent_view_ui from "./recent_view_ui"; -import * as recent_view_util from "./recent_view_util"; -import * as resize from "./resize"; -import * as scheduled_messages_feed_ui from "./scheduled_messages_feed_ui"; -import {web_mark_read_on_scroll_policy_values} from "./settings_config"; -import * as spectators from "./spectators"; -import type {NarrowTerm} from "./state_data"; -import {realm} from "./state_data"; -import * as stream_data from "./stream_data"; -import * as stream_list from "./stream_list"; -import * as submessage from "./submessage"; -import * as topic_generator from "./topic_generator"; -import * as typing_events from "./typing_events"; -import * as unread_ops from "./unread_ops"; -import * as unread_ui from "./unread_ui"; -import {user_settings} from "./user_settings"; -import * as util from "./util"; +import * as activity_ui from "./activity_ui.ts"; +import {all_messages_data} from "./all_messages_data.ts"; +import * as blueslip from "./blueslip.ts"; +import * as browser_history from "./browser_history.ts"; +import * as channel from "./channel.ts"; +import * as compose_actions from "./compose_actions.ts"; +import * as compose_banner from "./compose_banner.ts"; +import * as compose_closed_ui from "./compose_closed_ui.ts"; +import * as compose_notifications from "./compose_notifications.ts"; +import * as compose_recipient from "./compose_recipient.ts"; +import * as compose_state from "./compose_state.ts"; +import * as condense from "./condense.ts"; +import * as feedback_widget from "./feedback_widget.ts"; +import type {FetchStatus} from "./fetch_status.ts"; +import {Filter} from "./filter.ts"; +import * as hash_parser from "./hash_parser.ts"; +import * as hash_util from "./hash_util.ts"; +import {$t} from "./i18n.ts"; +import * as inbox_ui from "./inbox_ui.ts"; +import * as inbox_util from "./inbox_util.ts"; +import * as left_sidebar_navigation_area from "./left_sidebar_navigation_area.ts"; +import * as message_edit from "./message_edit.ts"; +import * as message_feed_loading from "./message_feed_loading.ts"; +import * as message_feed_top_notices from "./message_feed_top_notices.ts"; +import * as message_fetch from "./message_fetch.ts"; +import * as message_helper from "./message_helper.ts"; +import type {MessageList, SelectIdOpts} from "./message_list.ts"; +import * as message_list from "./message_list.ts"; +import {MessageListData} from "./message_list_data.ts"; +import * as message_list_data_cache from "./message_list_data_cache.ts"; +import * as message_lists from "./message_lists.ts"; +import * as message_scroll_state from "./message_scroll_state.ts"; +import {raw_message_schema} from "./message_store.ts"; +import * as message_store from "./message_store.ts"; +import * as message_view_header from "./message_view_header.ts"; +import * as message_viewport from "./message_viewport.ts"; +import * as narrow_banner from "./narrow_banner.ts"; +import * as narrow_history from "./narrow_history.ts"; +import * as narrow_state from "./narrow_state.ts"; +import * as narrow_title from "./narrow_title.ts"; +import {page_params} from "./page_params.ts"; +import * as people from "./people.ts"; +import * as pm_list from "./pm_list.ts"; +import * as recent_view_ui from "./recent_view_ui.ts"; +import * as recent_view_util from "./recent_view_util.ts"; +import * as resize from "./resize.ts"; +import * as scheduled_messages_feed_ui from "./scheduled_messages_feed_ui.ts"; +import {web_mark_read_on_scroll_policy_values} from "./settings_config.ts"; +import * as spectators from "./spectators.ts"; +import type {NarrowTerm} from "./state_data.ts"; +import {realm} from "./state_data.ts"; +import * as stream_data from "./stream_data.ts"; +import * as stream_list from "./stream_list.ts"; +import * as submessage from "./submessage.ts"; +import * as topic_generator from "./topic_generator.ts"; +import * as typing_events from "./typing_events.ts"; +import * as unread_ops from "./unread_ops.ts"; +import * as unread_ui from "./unread_ui.ts"; +import {user_settings} from "./user_settings.ts"; +import * as util from "./util.ts"; const LARGER_THAN_MAX_MESSAGE_ID = 10000000000000000; diff --git a/web/src/message_view_header.ts b/web/src/message_view_header.ts index b4bb89b9b8..a5832104a8 100644 --- a/web/src/message_view_header.ts +++ b/web/src/message_view_header.ts @@ -3,20 +3,20 @@ import assert from "minimalistic-assert"; import render_message_view_header from "../templates/message_view_header.hbs"; -import type {Filter} from "./filter"; -import * as hash_util from "./hash_util"; -import {$t} from "./i18n"; -import * as inbox_util from "./inbox_util"; -import * as narrow_state from "./narrow_state"; -import {page_params} from "./page_params"; -import * as peer_data from "./peer_data"; -import * as recent_view_util from "./recent_view_util"; -import * as rendered_markdown from "./rendered_markdown"; -import * as search from "./search"; -import {current_user} from "./state_data"; -import * as stream_data from "./stream_data"; -import type {SettingsSubscription} from "./stream_settings_data"; -import type {StreamSubscription} from "./sub_store"; +import type {Filter} from "./filter.ts"; +import * as hash_util from "./hash_util.ts"; +import {$t} from "./i18n.ts"; +import * as inbox_util from "./inbox_util.ts"; +import * as narrow_state from "./narrow_state.ts"; +import {page_params} from "./page_params.ts"; +import * as peer_data from "./peer_data.ts"; +import * as recent_view_util from "./recent_view_util.ts"; +import * as rendered_markdown from "./rendered_markdown.ts"; +import * as search from "./search.ts"; +import {current_user} from "./state_data.ts"; +import * as stream_data from "./stream_data.ts"; +import type {SettingsSubscription} from "./stream_settings_data.ts"; +import type {StreamSubscription} from "./sub_store.ts"; type MessageViewHeaderContext = { title: string; diff --git a/web/src/message_viewport.ts b/web/src/message_viewport.ts index b996be6a7c..c921242e10 100644 --- a/web/src/message_viewport.ts +++ b/web/src/message_viewport.ts @@ -1,12 +1,12 @@ import $ from "jquery"; import assert from "minimalistic-assert"; -import * as blueslip from "./blueslip"; -import * as message_lists from "./message_lists"; -import * as message_scroll_state from "./message_scroll_state"; -import type {Message} from "./message_store"; -import * as rows from "./rows"; -import * as util from "./util"; +import * as blueslip from "./blueslip.ts"; +import * as message_lists from "./message_lists.ts"; +import * as message_scroll_state from "./message_scroll_state.ts"; +import type {Message} from "./message_store.ts"; +import * as rows from "./rows.ts"; +import * as util from "./util.ts"; export type MessageViewportInfo = { visible_top: number; diff --git a/web/src/messages_overlay_ui.ts b/web/src/messages_overlay_ui.ts index 2a624e1d8a..fc2b64b924 100644 --- a/web/src/messages_overlay_ui.ts +++ b/web/src/messages_overlay_ui.ts @@ -1,7 +1,7 @@ import $ from "jquery"; import assert from "minimalistic-assert"; -import * as util from "./util"; +import * as util from "./util.ts"; export type Context = { items_container_selector: string; diff --git a/web/src/modals.ts b/web/src/modals.ts index 392ffe9d95..051a25e465 100644 --- a/web/src/modals.ts +++ b/web/src/modals.ts @@ -2,8 +2,8 @@ import $ from "jquery"; import Micromodal from "micromodal"; import assert from "minimalistic-assert"; -import * as blueslip from "./blueslip"; -import * as overlay_util from "./overlay_util"; +import * as blueslip from "./blueslip.ts"; +import * as overlay_util from "./overlay_util.ts"; type Hook = () => void; diff --git a/web/src/muted_users.ts b/web/src/muted_users.ts index d1640fe5d0..64f450f22c 100644 --- a/web/src/muted_users.ts +++ b/web/src/muted_users.ts @@ -1,9 +1,9 @@ import type {z} from "zod"; -import * as channel from "./channel"; -import type {StateData, muted_user_schema} from "./state_data"; -import * as timerender from "./timerender"; -import {get_time_from_date_muted} from "./util"; +import * as channel from "./channel.ts"; +import type {StateData, muted_user_schema} from "./state_data.ts"; +import * as timerender from "./timerender.ts"; +import {get_time_from_date_muted} from "./util.ts"; export type RawMutedUser = z.infer; diff --git a/web/src/muted_users_ui.ts b/web/src/muted_users_ui.ts index d455e9cd62..b5dc4a1651 100644 --- a/web/src/muted_users_ui.ts +++ b/web/src/muted_users_ui.ts @@ -1,12 +1,12 @@ -import * as activity_ui from "./activity_ui"; -import * as message_lists from "./message_lists"; -import * as muted_users from "./muted_users"; -import type {RawMutedUser} from "./muted_users"; -import * as overlays from "./overlays"; -import * as pm_list from "./pm_list"; -import * as popovers from "./popovers"; -import * as recent_view_ui from "./recent_view_ui"; -import * as settings_muted_users from "./settings_muted_users"; +import * as activity_ui from "./activity_ui.ts"; +import * as message_lists from "./message_lists.ts"; +import * as muted_users from "./muted_users.ts"; +import type {RawMutedUser} from "./muted_users.ts"; +import * as overlays from "./overlays.ts"; +import * as pm_list from "./pm_list.ts"; +import * as popovers from "./popovers.ts"; +import * as recent_view_ui from "./recent_view_ui.ts"; +import * as settings_muted_users from "./settings_muted_users.ts"; export function rerender_for_muted_user(): void { for (const msg_list of message_lists.all_rendered_message_lists()) { diff --git a/web/src/narrow_banner.ts b/web/src/narrow_banner.ts index c057651037..8774e3d8e7 100644 --- a/web/src/narrow_banner.ts +++ b/web/src/narrow_banner.ts @@ -2,17 +2,17 @@ import $ from "jquery"; import _ from "lodash"; import assert from "minimalistic-assert"; -import * as compose_validate from "./compose_validate"; -import {$t, $t_html} from "./i18n"; -import type {NarrowBannerData, SearchData} from "./narrow_error"; -import {narrow_error} from "./narrow_error"; -import * as narrow_state from "./narrow_state"; -import {page_params} from "./page_params"; -import * as people from "./people"; -import * as spectators from "./spectators"; -import {realm} from "./state_data"; -import * as stream_data from "./stream_data"; -import * as util from "./util"; +import * as compose_validate from "./compose_validate.ts"; +import {$t, $t_html} from "./i18n.ts"; +import type {NarrowBannerData, SearchData} from "./narrow_error.ts"; +import {narrow_error} from "./narrow_error.ts"; +import * as narrow_state from "./narrow_state.ts"; +import {page_params} from "./page_params.ts"; +import * as people from "./people.ts"; +import * as spectators from "./spectators.ts"; +import {realm} from "./state_data.ts"; +import * as stream_data from "./stream_data.ts"; +import * as util from "./util.ts"; const SPECTATOR_STREAM_NARROW_BANNER = { title: "", diff --git a/web/src/narrow_history.ts b/web/src/narrow_history.ts index 354829d5b1..e2be1770cf 100644 --- a/web/src/narrow_history.ts +++ b/web/src/narrow_history.ts @@ -1,11 +1,11 @@ import _ from "lodash"; import assert from "minimalistic-assert"; -import * as browser_history from "./browser_history"; -import type {Filter} from "./filter"; -import * as hash_util from "./hash_util"; -import * as message_lists from "./message_lists"; -import * as narrow_state from "./narrow_state"; +import * as browser_history from "./browser_history.ts"; +import type {Filter} from "./filter.ts"; +import * as hash_util from "./hash_util.ts"; +import * as message_lists from "./message_lists.ts"; +import * as narrow_state from "./narrow_state.ts"; function is_URL_hash_same_as_filter_hash(filter: Filter): boolean { if (filter.is_in_home()) { diff --git a/web/src/narrow_state.ts b/web/src/narrow_state.ts index 04421dc4da..efc2ecc6cb 100644 --- a/web/src/narrow_state.ts +++ b/web/src/narrow_state.ts @@ -1,14 +1,14 @@ import assert from "minimalistic-assert"; -import * as blueslip from "./blueslip"; -import {Filter} from "./filter"; -import * as message_lists from "./message_lists"; -import {page_params} from "./page_params"; -import * as people from "./people"; -import type {NarrowTerm} from "./state_data"; -import * as stream_data from "./stream_data"; -import type {StreamSubscription} from "./sub_store"; -import * as unread from "./unread"; +import * as blueslip from "./blueslip.ts"; +import {Filter} from "./filter.ts"; +import * as message_lists from "./message_lists.ts"; +import {page_params} from "./page_params.ts"; +import * as people from "./people.ts"; +import type {NarrowTerm} from "./state_data.ts"; +import * as stream_data from "./stream_data.ts"; +import type {StreamSubscription} from "./sub_store.ts"; +import * as unread from "./unread.ts"; export function filter(): Filter | undefined { // `Recent Conversations` and `Inbox` return undefined; diff --git a/web/src/narrow_title.ts b/web/src/narrow_title.ts index 5c3b9d39c2..1c11a3209e 100644 --- a/web/src/narrow_title.ts +++ b/web/src/narrow_title.ts @@ -1,17 +1,17 @@ import _ from "lodash"; import assert from "minimalistic-assert"; -import {electron_bridge} from "./electron_bridge"; -import * as favicon from "./favicon"; -import type {Filter} from "./filter"; -import {$t} from "./i18n"; -import * as inbox_util from "./inbox_util"; -import * as people from "./people"; -import * as recent_view_util from "./recent_view_util"; -import {realm} from "./state_data"; -import * as stream_data from "./stream_data"; -import * as unread from "./unread"; -import type {FullUnreadCountsData} from "./unread"; +import {electron_bridge} from "./electron_bridge.ts"; +import * as favicon from "./favicon.ts"; +import type {Filter} from "./filter.ts"; +import {$t} from "./i18n.ts"; +import * as inbox_util from "./inbox_util.ts"; +import * as people from "./people.ts"; +import * as recent_view_util from "./recent_view_util.ts"; +import {realm} from "./state_data.ts"; +import * as stream_data from "./stream_data.ts"; +import * as unread from "./unread.ts"; +import type {FullUnreadCountsData} from "./unread.ts"; export let unread_count = 0; let pm_count = 0; diff --git a/web/src/navbar_alerts.ts b/web/src/navbar_alerts.ts index 769a6e3e78..b7877acc00 100644 --- a/web/src/navbar_alerts.ts +++ b/web/src/navbar_alerts.ts @@ -12,18 +12,18 @@ import render_navbar_alert_wrapper from "../templates/navbar_alerts/navbar_alert import render_profile_incomplete_alert_content from "../templates/navbar_alerts/profile_incomplete.hbs"; import render_server_needs_upgrade_alert_content from "../templates/navbar_alerts/server_needs_upgrade.hbs"; -import * as desktop_notifications from "./desktop_notifications"; -import * as keydown_util from "./keydown_util"; -import type {LocalStorage} from "./localstorage"; -import {localstorage} from "./localstorage"; -import {page_params} from "./page_params"; -import * as people from "./people"; -import {current_user, realm} from "./state_data"; -import {should_display_profile_incomplete_alert} from "./timerender"; -import * as unread from "./unread"; -import * as unread_ops from "./unread_ops"; -import * as unread_ui from "./unread_ui"; -import * as util from "./util"; +import * as desktop_notifications from "./desktop_notifications.ts"; +import * as keydown_util from "./keydown_util.ts"; +import type {LocalStorage} from "./localstorage.ts"; +import {localstorage} from "./localstorage.ts"; +import {page_params} from "./page_params.ts"; +import * as people from "./people.ts"; +import {current_user, realm} from "./state_data.ts"; +import {should_display_profile_incomplete_alert} from "./timerender.ts"; +import * as unread from "./unread.ts"; +import * as unread_ops from "./unread_ops.ts"; +import * as unread_ui from "./unread_ui.ts"; +import * as util from "./util.ts"; const show_step = function ($process: JQuery, step: number): void { $process diff --git a/web/src/navbar_help_menu.ts b/web/src/navbar_help_menu.ts index 1c38f09986..b0969c291a 100644 --- a/web/src/navbar_help_menu.ts +++ b/web/src/navbar_help_menu.ts @@ -2,9 +2,9 @@ import $ from "jquery"; import render_navbar_help_menu from "../templates/popovers/navbar/navbar_help_menu_popover.hbs"; -import {page_params} from "./page_params"; -import * as popover_menus from "./popover_menus"; -import {parse_html} from "./ui_util"; +import {page_params} from "./page_params.ts"; +import * as popover_menus from "./popover_menus.ts"; +import {parse_html} from "./ui_util.ts"; export function initialize(): void { popover_menus.register_popover_menu("#help-menu", { diff --git a/web/src/navbar_menus.js b/web/src/navbar_menus.js index c9843cae70..b4489197c9 100644 --- a/web/src/navbar_menus.js +++ b/web/src/navbar_menus.js @@ -1,8 +1,8 @@ -import * as gear_menu from "./gear_menu"; -import * as navbar_help_menu from "./navbar_help_menu"; -import {page_params} from "./page_params"; -import * as personal_menu_popover from "./personal_menu_popover"; -import * as popover_menus from "./popover_menus"; +import * as gear_menu from "./gear_menu.js"; +import * as navbar_help_menu from "./navbar_help_menu.ts"; +import {page_params} from "./page_params.ts"; +import * as personal_menu_popover from "./personal_menu_popover.ts"; +import * as popover_menus from "./popover_menus.ts"; export function is_navbar_menus_displayed() { return ( diff --git a/web/src/navigate.js b/web/src/navigate.js index 4e8e357802..2b88ced946 100644 --- a/web/src/navigate.js +++ b/web/src/navigate.js @@ -1,9 +1,9 @@ import assert from "minimalistic-assert"; -import * as message_lists from "./message_lists"; -import * as message_view from "./message_view"; -import * as message_viewport from "./message_viewport"; -import * as unread_ops from "./unread_ops"; +import * as message_lists from "./message_lists.ts"; +import * as message_view from "./message_view.ts"; +import * as message_viewport from "./message_viewport.ts"; +import * as unread_ops from "./unread_ops.ts"; function go_to_row(msg_id) { assert(message_lists.current !== undefined); diff --git a/web/src/onboarding_steps.ts b/web/src/onboarding_steps.ts index 6548f03a0f..23903ba775 100644 --- a/web/src/onboarding_steps.ts +++ b/web/src/onboarding_steps.ts @@ -1,9 +1,9 @@ import type {z} from "zod"; -import * as blueslip from "./blueslip"; -import * as channel from "./channel"; -import * as people from "./people"; -import type {NarrowTerm, StateData, onboarding_step_schema} from "./state_data"; +import * as blueslip from "./blueslip.ts"; +import * as channel from "./channel.ts"; +import * as people from "./people.ts"; +import type {NarrowTerm, StateData, onboarding_step_schema} from "./state_data.ts"; export type OnboardingStep = z.output; diff --git a/web/src/overlays.ts b/web/src/overlays.ts index 6a3cc00622..a1a9556093 100644 --- a/web/src/overlays.ts +++ b/web/src/overlays.ts @@ -1,7 +1,7 @@ import $ from "jquery"; -import * as blueslip from "./blueslip"; -import * as overlay_util from "./overlay_util"; +import * as blueslip from "./blueslip.ts"; +import * as overlay_util from "./overlay_util.ts"; type Hook = () => void; diff --git a/web/src/page_params.ts b/web/src/page_params.ts index a5150da4f9..df7c314de1 100644 --- a/web/src/page_params.ts +++ b/web/src/page_params.ts @@ -1,6 +1,6 @@ import assert from "minimalistic-assert"; -import {page_params as base_page_params} from "./base_page_params"; +import {page_params as base_page_params} from "./base_page_params.ts"; assert(base_page_params.page_type === "home"); diff --git a/web/src/password_quality.ts b/web/src/password_quality.ts index 55d7d6fbee..1ee4db2c3d 100644 --- a/web/src/password_quality.ts +++ b/web/src/password_quality.ts @@ -2,7 +2,7 @@ import {zxcvbn, zxcvbnOptions} from "@zxcvbn-ts/core"; import * as zxcvbnCommonPackage from "@zxcvbn-ts/language-common"; import * as zxcvbnEnPackage from "@zxcvbn-ts/language-en"; -import {$t} from "./i18n"; +import {$t} from "./i18n.ts"; zxcvbnOptions.setOptions({ translations: zxcvbnEnPackage.translations, diff --git a/web/src/peer_data.ts b/web/src/peer_data.ts index 1e072e19f5..85319d2600 100644 --- a/web/src/peer_data.ts +++ b/web/src/peer_data.ts @@ -1,8 +1,8 @@ -import * as blueslip from "./blueslip"; -import {LazySet} from "./lazy_set"; -import type {User} from "./people"; -import * as people from "./people"; -import * as sub_store from "./sub_store"; +import * as blueslip from "./blueslip.ts"; +import {LazySet} from "./lazy_set.ts"; +import type {User} from "./people.ts"; +import * as people from "./people.ts"; +import * as sub_store from "./sub_store.ts"; // This maps a stream_id to a LazySet of user_ids who are subscribed. const stream_subscribers = new Map(); diff --git a/web/src/people.ts b/web/src/people.ts index c06615b5bb..dddd81f499 100644 --- a/web/src/people.ts +++ b/web/src/people.ts @@ -2,24 +2,24 @@ import md5 from "blueimp-md5"; import assert from "minimalistic-assert"; import type {z} from "zod"; -import * as typeahead from "../shared/src/typeahead"; +import * as typeahead from "../shared/src/typeahead.ts"; -import * as blueslip from "./blueslip"; -import {FoldDict} from "./fold_dict"; -import {$t} from "./i18n"; -import type {DisplayRecipientUser, Message, MessageWithBooleans} from "./message_store"; -import * as message_user_ids from "./message_user_ids"; -import * as muted_users from "./muted_users"; -import {page_params} from "./page_params"; -import * as reload_state from "./reload_state"; -import * as settings_config from "./settings_config"; -import * as settings_data from "./settings_data"; -import type {StateData, profile_datum_schema, user_schema} from "./state_data"; -import {current_user, realm} from "./state_data"; -import * as timerender from "./timerender"; -import {is_user_in_setting_group} from "./user_groups"; -import {user_settings} from "./user_settings"; -import * as util from "./util"; +import * as blueslip from "./blueslip.ts"; +import {FoldDict} from "./fold_dict.ts"; +import {$t} from "./i18n.ts"; +import type {DisplayRecipientUser, Message, MessageWithBooleans} from "./message_store.ts"; +import * as message_user_ids from "./message_user_ids.ts"; +import * as muted_users from "./muted_users.ts"; +import {page_params} from "./page_params.ts"; +import * as reload_state from "./reload_state.ts"; +import * as settings_config from "./settings_config.ts"; +import * as settings_data from "./settings_data.ts"; +import type {StateData, profile_datum_schema, user_schema} from "./state_data.ts"; +import {current_user, realm} from "./state_data.ts"; +import * as timerender from "./timerender.ts"; +import {is_user_in_setting_group} from "./user_groups.ts"; +import {user_settings} from "./user_settings.ts"; +import * as util from "./util.ts"; export type ProfileDatum = z.infer; export type User = z.infer; diff --git a/web/src/personal_menu_popover.ts b/web/src/personal_menu_popover.ts index a5c08be3da..227c75d196 100644 --- a/web/src/personal_menu_popover.ts +++ b/web/src/personal_menu_popover.ts @@ -2,16 +2,16 @@ import $ from "jquery"; import render_navbar_personal_menu_popover from "../templates/popovers/navbar/navbar_personal_menu_popover.hbs"; -import * as channel from "./channel"; -import * as message_view from "./message_view"; -import * as people from "./people"; -import * as popover_menus from "./popover_menus"; -import * as popover_menus_data from "./popover_menus_data"; -import * as popovers from "./popovers"; -import {current_user} from "./state_data"; -import {parse_html} from "./ui_util"; -import {user_settings} from "./user_settings"; -import * as user_status from "./user_status"; +import * as channel from "./channel.ts"; +import * as message_view from "./message_view.ts"; +import * as people from "./people.ts"; +import * as popover_menus from "./popover_menus.ts"; +import * as popover_menus_data from "./popover_menus_data.ts"; +import * as popovers from "./popovers.ts"; +import {current_user} from "./state_data.ts"; +import {parse_html} from "./ui_util.ts"; +import {user_settings} from "./user_settings.ts"; +import * as user_status from "./user_status.ts"; export function initialize(): void { popover_menus.register_popover_menu("#personal-menu", { diff --git a/web/src/pill_typeahead.ts b/web/src/pill_typeahead.ts index 5b49d83b56..13c0bc58ec 100644 --- a/web/src/pill_typeahead.ts +++ b/web/src/pill_typeahead.ts @@ -1,19 +1,19 @@ import assert from "minimalistic-assert"; -import * as blueslip from "./blueslip"; -import {Typeahead} from "./bootstrap_typeahead"; -import type {TypeaheadInputElement} from "./bootstrap_typeahead"; -import * as people from "./people"; -import type {User} from "./people"; -import * as stream_pill from "./stream_pill"; -import type {StreamPillData, StreamPillWidget} from "./stream_pill"; -import * as typeahead_helper from "./typeahead_helper"; -import type {CombinedPillContainer, GroupSettingPillContainer} from "./typeahead_helper"; -import * as user_group_pill from "./user_group_pill"; -import type {UserGroupPillData} from "./user_group_pill"; -import type {UserGroup} from "./user_groups"; -import * as user_pill from "./user_pill"; -import type {UserPillData, UserPillWidget} from "./user_pill"; +import * as blueslip from "./blueslip.ts"; +import {Typeahead} from "./bootstrap_typeahead.ts"; +import type {TypeaheadInputElement} from "./bootstrap_typeahead.ts"; +import * as people from "./people.ts"; +import type {User} from "./people.ts"; +import * as stream_pill from "./stream_pill.ts"; +import type {StreamPillData, StreamPillWidget} from "./stream_pill.ts"; +import * as typeahead_helper from "./typeahead_helper.ts"; +import type {CombinedPillContainer, GroupSettingPillContainer} from "./typeahead_helper.ts"; +import * as user_group_pill from "./user_group_pill.ts"; +import type {UserGroupPillData} from "./user_group_pill.ts"; +import type {UserGroup} from "./user_groups.ts"; +import * as user_pill from "./user_pill.ts"; +import type {UserPillData, UserPillWidget} from "./user_pill.ts"; function person_matcher(query: string, item: UserPillData): boolean { return ( diff --git a/web/src/playground_links_popover.ts b/web/src/playground_links_popover.ts index 5e40bcc63d..87ad7351ad 100644 --- a/web/src/playground_links_popover.ts +++ b/web/src/playground_links_popover.ts @@ -4,12 +4,12 @@ import url_template_lib from "url-template"; import render_playground_links_popover from "../templates/popovers/playground_links_popover.hbs"; -import * as blueslip from "./blueslip"; -import * as popover_menus from "./popover_menus"; -import * as realm_playground from "./realm_playground"; -import type {RealmPlayground} from "./realm_playground"; -import * as ui_util from "./ui_util"; -import * as util from "./util"; +import * as blueslip from "./blueslip.ts"; +import * as popover_menus from "./popover_menus.ts"; +import * as realm_playground from "./realm_playground.ts"; +import type {RealmPlayground} from "./realm_playground.ts"; +import * as ui_util from "./ui_util.ts"; +import * as util from "./util.ts"; type RealmPlaygroundWithURL = RealmPlayground & {playground_url: string}; diff --git a/web/src/pm_conversations.ts b/web/src/pm_conversations.ts index 83617bb3e2..60289ebf0b 100644 --- a/web/src/pm_conversations.ts +++ b/web/src/pm_conversations.ts @@ -1,8 +1,8 @@ -import {FoldDict} from "./fold_dict"; -import type {Message} from "./message_store"; -import * as muted_users from "./muted_users"; -import * as people from "./people"; -import type {StateData} from "./state_data"; +import {FoldDict} from "./fold_dict.ts"; +import type {Message} from "./message_store.ts"; +import * as muted_users from "./muted_users.ts"; +import * as people from "./people.ts"; +import type {StateData} from "./state_data.ts"; type PMConversation = { user_ids_string: string; diff --git a/web/src/pm_list.ts b/web/src/pm_list.ts index 71d4dc0e27..90e6acf725 100644 --- a/web/src/pm_list.ts +++ b/web/src/pm_list.ts @@ -1,15 +1,15 @@ import $ from "jquery"; import _ from "lodash"; -import type {Filter} from "./filter"; -import * as pm_list_data from "./pm_list_data"; -import * as pm_list_dom from "./pm_list_dom"; -import type {PMNode} from "./pm_list_dom"; -import * as resize from "./resize"; -import * as scroll_util from "./scroll_util"; -import * as ui_util from "./ui_util"; -import type {FullUnreadCountsData} from "./unread"; -import * as vdom from "./vdom"; +import type {Filter} from "./filter.ts"; +import * as pm_list_data from "./pm_list_data.ts"; +import * as pm_list_dom from "./pm_list_dom.ts"; +import type {PMNode} from "./pm_list_dom.ts"; +import * as resize from "./resize.ts"; +import * as scroll_util from "./scroll_util.ts"; +import * as ui_util from "./ui_util.ts"; +import type {FullUnreadCountsData} from "./unread.ts"; +import * as vdom from "./vdom.ts"; let prior_dom: vdom.Tag | undefined; diff --git a/web/src/pm_list_data.ts b/web/src/pm_list_data.ts index b877eff5e1..7ecbf0a685 100644 --- a/web/src/pm_list_data.ts +++ b/web/src/pm_list_data.ts @@ -1,13 +1,13 @@ import assert from "minimalistic-assert"; -import * as buddy_data from "./buddy_data"; -import * as hash_util from "./hash_util"; -import * as narrow_state from "./narrow_state"; -import * as people from "./people"; -import * as pm_conversations from "./pm_conversations"; -import * as unread from "./unread"; -import * as user_status from "./user_status"; -import type {UserStatusEmojiInfo} from "./user_status"; +import * as buddy_data from "./buddy_data.ts"; +import * as hash_util from "./hash_util.ts"; +import * as narrow_state from "./narrow_state.ts"; +import * as people from "./people.ts"; +import * as pm_conversations from "./pm_conversations.ts"; +import * as unread from "./unread.ts"; +import * as user_status from "./user_status.ts"; +import type {UserStatusEmojiInfo} from "./user_status.ts"; // Maximum number of conversation threads to show in default view. const max_conversations_to_show = 8; diff --git a/web/src/pm_list_dom.ts b/web/src/pm_list_dom.ts index b20bf2e8c5..07d9b23c58 100644 --- a/web/src/pm_list_dom.ts +++ b/web/src/pm_list_dom.ts @@ -3,7 +3,7 @@ import _ from "lodash"; import render_more_private_conversations from "../templates/more_pms.hbs"; import render_pm_list_item from "../templates/pm_list_item.hbs"; -import * as vdom from "./vdom"; +import * as vdom from "./vdom.ts"; // TODO/typescript: Move this to pm_list_data type PMListConversation = { diff --git a/web/src/poll_modal.ts b/web/src/poll_modal.ts index 2fa1201977..18d95d2667 100644 --- a/web/src/poll_modal.ts +++ b/web/src/poll_modal.ts @@ -3,7 +3,7 @@ import SortableJS from "sortablejs"; import render_poll_modal_option from "../templates/poll_modal_option.hbs"; -import * as util from "./util"; +import * as util from "./util.ts"; function create_option_row($last_option_row_input: JQuery): void { const row_html = render_poll_modal_option(); diff --git a/web/src/poll_widget.ts b/web/src/poll_widget.ts index aea575536d..d8ffccb7ac 100644 --- a/web/src/poll_widget.ts +++ b/web/src/poll_widget.ts @@ -1,20 +1,20 @@ import $ from "jquery"; -import {PollData} from "../shared/src/poll_data"; +import {PollData} from "../shared/src/poll_data.ts"; import type { InboundData, NewOptionOutboundData, QuestionOutboundData, VoteOutboundData, -} from "../shared/src/poll_data"; +} from "../shared/src/poll_data.ts"; import render_widgets_poll_widget from "../templates/widgets/poll_widget.hbs"; import render_widgets_poll_widget_results from "../templates/widgets/poll_widget_results.hbs"; -import * as blueslip from "./blueslip"; -import {$t} from "./i18n"; -import * as keydown_util from "./keydown_util"; -import type {Message} from "./message_store"; -import * as people from "./people"; +import * as blueslip from "./blueslip.ts"; +import {$t} from "./i18n.ts"; +import * as keydown_util from "./keydown_util.ts"; +import type {Message} from "./message_store.ts"; +import * as people from "./people.ts"; export type Event = {sender_id: number; data: InboundData}; diff --git a/web/src/popover_menus.ts b/web/src/popover_menus.ts index a548d95c18..caf03c2118 100644 --- a/web/src/popover_menus.ts +++ b/web/src/popover_menus.ts @@ -5,12 +5,12 @@ import $ from "jquery"; import * as tippy from "tippy.js"; -import * as blueslip from "./blueslip"; -import {media_breakpoints_num} from "./css_variables"; -import * as modals from "./modals"; -import * as overlays from "./overlays"; -import * as popovers from "./popovers"; -import * as util from "./util"; +import * as blueslip from "./blueslip.ts"; +import {media_breakpoints_num} from "./css_variables.js"; +import * as modals from "./modals.ts"; +import * as overlays from "./overlays.ts"; +import * as popovers from "./popovers.ts"; +import * as util from "./util.ts"; type PopoverName = | "compose_control_buttons" diff --git a/web/src/popover_menus_data.ts b/web/src/popover_menus_data.ts index 5774796cab..bef05ece07 100644 --- a/web/src/popover_menus_data.ts +++ b/web/src/popover_menus_data.ts @@ -3,30 +3,30 @@ import assert from "minimalistic-assert"; -import * as resolved_topic from "../shared/src/resolved_topic"; +import * as resolved_topic from "../shared/src/resolved_topic.ts"; -import * as buddy_data from "./buddy_data"; -import * as gear_menu_util from "./gear_menu_util"; -import * as hash_util from "./hash_util"; -import {$t} from "./i18n"; -import * as message_edit from "./message_edit"; -import * as message_lists from "./message_lists"; -import * as muted_users from "./muted_users"; -import {page_params} from "./page_params"; -import * as people from "./people"; -import * as settings_config from "./settings_config"; -import type {ColorSchemeValues} from "./settings_config"; -import * as settings_data from "./settings_data"; -import * as starred_messages from "./starred_messages"; -import {current_user, realm} from "./state_data"; -import * as stream_data from "./stream_data"; -import * as sub_store from "./sub_store"; -import {num_unread_for_topic} from "./unread"; -import {user_settings} from "./user_settings"; -import * as user_status from "./user_status"; -import type {UserStatusEmojiInfo} from "./user_status"; -import * as user_topics from "./user_topics"; -import type {AllVisibilityPolicies} from "./user_topics"; +import * as buddy_data from "./buddy_data.ts"; +import * as gear_menu_util from "./gear_menu_util.ts"; +import * as hash_util from "./hash_util.ts"; +import {$t} from "./i18n.ts"; +import * as message_edit from "./message_edit.ts"; +import * as message_lists from "./message_lists.ts"; +import * as muted_users from "./muted_users.ts"; +import {page_params} from "./page_params.ts"; +import * as people from "./people.ts"; +import * as settings_config from "./settings_config.ts"; +import type {ColorSchemeValues} from "./settings_config.ts"; +import * as settings_data from "./settings_data.ts"; +import * as starred_messages from "./starred_messages.ts"; +import {current_user, realm} from "./state_data.ts"; +import * as stream_data from "./stream_data.ts"; +import * as sub_store from "./sub_store.ts"; +import {num_unread_for_topic} from "./unread.ts"; +import {user_settings} from "./user_settings.ts"; +import * as user_status from "./user_status.ts"; +import type {UserStatusEmojiInfo} from "./user_status.ts"; +import * as user_topics from "./user_topics.ts"; +import type {AllVisibilityPolicies} from "./user_topics.ts"; type ActionPopoverContext = { message_id: number; diff --git a/web/src/portico/desktop-login.ts b/web/src/portico/desktop-login.ts index a3d818e004..0292bb321a 100644 --- a/web/src/portico/desktop-login.ts +++ b/web/src/portico/desktop-login.ts @@ -1,4 +1,4 @@ -import {electron_bridge} from "../electron_bridge"; +import {electron_bridge} from "../electron_bridge.ts"; document.querySelector("form#form")!.addEventListener("submit", () => { document.querySelector("p#bad-token")!.hidden = false; diff --git a/web/src/portico/email_log.ts b/web/src/portico/email_log.ts index 0566ecdd46..af48f2d15c 100644 --- a/web/src/portico/email_log.ts +++ b/web/src/portico/email_log.ts @@ -1,8 +1,8 @@ import $ from "jquery"; -import * as channel from "../channel"; +import * as channel from "../channel.ts"; -import * as portico_modals from "./portico_modals"; +import * as portico_modals from "./portico_modals.ts"; $(() => { // This code will be executed when the user visits /emails in diff --git a/web/src/portico/google-analytics.ts b/web/src/portico/google-analytics.ts index 5e2a9f2d7a..0e7ac17cd8 100644 --- a/web/src/portico/google-analytics.ts +++ b/web/src/portico/google-analytics.ts @@ -1,7 +1,7 @@ import {gtag, install} from "ga-gtag"; import type {ConfigParams} from "ga-gtag"; -import {page_params} from "../base_page_params"; +import {page_params} from "../base_page_params.ts"; export let config: (info: ConfigParams) => void; diff --git a/web/src/portico/help.ts b/web/src/portico/help.ts index 395d0ad464..57a0b70848 100644 --- a/web/src/portico/help.ts +++ b/web/src/portico/help.ts @@ -5,11 +5,11 @@ import SimpleBar from "simplebar"; import * as tippy from "tippy.js"; import zulip_copy_icon from "../../templates/zulip_copy_icon.hbs"; -import * as common from "../common"; -import {show_copied_confirmation} from "../copied_tooltip"; -import * as util from "../util"; +import * as common from "../common.ts"; +import {show_copied_confirmation} from "../copied_tooltip.ts"; +import * as util from "../util.ts"; -import {activate_correct_tab} from "./tabbed-instructions"; +import {activate_correct_tab} from "./tabbed-instructions.ts"; function register_tabbed_section($tabbed_section: JQuery): void { const $li = $tabbed_section.find("ul.nav li"); diff --git a/web/src/portico/integrations.js b/web/src/portico/integrations.js index 0aedf12764..86236963df 100644 --- a/web/src/portico/integrations.js +++ b/web/src/portico/integrations.js @@ -1,12 +1,12 @@ import $ from "jquery"; import _ from "lodash"; -import * as blueslip from "../blueslip"; -import * as common from "../common"; -import {$t} from "../i18n"; +import * as blueslip from "../blueslip.ts"; +import * as common from "../common.ts"; +import {$t} from "../i18n.ts"; -import * as google_analytics from "./google-analytics"; -import {path_parts} from "./landing-page"; +import * as google_analytics from "./google-analytics.ts"; +import {path_parts} from "./landing-page.ts"; // these constants are populated immediately with data from the DOM on page load // name -> display name diff --git a/web/src/portico/integrations_dev_panel.ts b/web/src/portico/integrations_dev_panel.ts index b47423e454..dec7ef7eed 100644 --- a/web/src/portico/integrations_dev_panel.ts +++ b/web/src/portico/integrations_dev_panel.ts @@ -2,8 +2,8 @@ import $ from "jquery"; import assert from "minimalistic-assert"; import {z} from "zod"; -import * as channel from "../channel"; -import * as util from "../util"; +import * as channel from "../channel.ts"; +import * as util from "../util.ts"; // Main JavaScript file for the integrations development panel at // /devtools/integrations. diff --git a/web/src/portico/landing-page.ts b/web/src/portico/landing-page.ts index 32f124d3ce..ee6a97f0f2 100644 --- a/web/src/portico/landing-page.ts +++ b/web/src/portico/landing-page.ts @@ -2,12 +2,12 @@ import $ from "jquery"; import assert from "minimalistic-assert"; import {z} from "zod"; -import {page_params} from "../base_page_params"; -import * as util from "../util"; +import {page_params} from "../base_page_params.ts"; +import * as util from "../util.ts"; -import type {UserOS} from "./tabbed-instructions"; -import {detect_user_os} from "./tabbed-instructions"; -import render_tabs from "./team"; +import type {UserOS} from "./tabbed-instructions.ts"; +import {detect_user_os} from "./tabbed-instructions.ts"; +import render_tabs from "./team.ts"; type VersionInfo = { description: string; diff --git a/web/src/portico/portico_modals.ts b/web/src/portico/portico_modals.ts index cd7c9c097f..fc48a8515f 100644 --- a/web/src/portico/portico_modals.ts +++ b/web/src/portico/portico_modals.ts @@ -2,7 +2,7 @@ import $ from "jquery"; import Micromodal from "micromodal"; import assert from "minimalistic-assert"; -import * as blueslip from "../blueslip"; +import * as blueslip from "../blueslip.ts"; function is_open(): boolean { return $(".micromodal").hasClass("modal--open"); diff --git a/web/src/portico/signup.ts b/web/src/portico/signup.ts index 2ea88c4c5f..82c3c486e5 100644 --- a/web/src/portico/signup.ts +++ b/web/src/portico/signup.ts @@ -2,12 +2,12 @@ import $ from "jquery"; import assert from "minimalistic-assert"; import {z} from "zod"; -import * as common from "../common"; -import {$t} from "../i18n"; -import {password_quality, password_warning} from "../password_quality"; -import * as settings_config from "../settings_config"; +import * as common from "../common.ts"; +import {$t} from "../i18n.ts"; +import {password_quality, password_warning} from "../password_quality.ts"; +import * as settings_config from "../settings_config.ts"; -import * as portico_modals from "./portico_modals"; +import * as portico_modals from "./portico_modals.ts"; $(() => { // NB: this file is included on multiple pages. In each context, diff --git a/web/src/portico/tabbed-instructions.ts b/web/src/portico/tabbed-instructions.ts index 05d03bf2a8..1db08d3cb3 100644 --- a/web/src/portico/tabbed-instructions.ts +++ b/web/src/portico/tabbed-instructions.ts @@ -1,8 +1,8 @@ import $ from "jquery"; -import * as blueslip from "../blueslip"; -import * as common from "../common"; -import * as util from "../util"; +import * as blueslip from "../blueslip.ts"; +import * as common from "../common.ts"; +import * as util from "../util.ts"; export type UserOS = "android" | "ios" | "mac" | "windows" | "linux"; diff --git a/web/src/postprocess_content.ts b/web/src/postprocess_content.ts index 75491ec11b..af2fc0315f 100644 --- a/web/src/postprocess_content.ts +++ b/web/src/postprocess_content.ts @@ -1,7 +1,7 @@ -import {$t} from "./i18n"; -import * as thumbnail from "./thumbnail"; -import {user_settings} from "./user_settings"; -import * as util from "./util"; +import {$t} from "./i18n.ts"; +import * as thumbnail from "./thumbnail.ts"; +import {user_settings} from "./user_settings.ts"; +import * as util from "./util.ts"; let inertDocument: Document | undefined; diff --git a/web/src/presence.ts b/web/src/presence.ts index 5c87acce62..737d609288 100644 --- a/web/src/presence.ts +++ b/web/src/presence.ts @@ -1,9 +1,9 @@ import type {z} from "zod"; -import * as people from "./people"; -import type {StateData, presence_schema} from "./state_data"; -import {realm} from "./state_data"; -import {user_settings} from "./user_settings"; +import * as people from "./people.ts"; +import type {StateData, presence_schema} from "./state_data.ts"; +import {realm} from "./state_data.ts"; +import {user_settings} from "./user_settings.ts"; export type RawPresence = z.infer & { server_timestamp: number; diff --git a/web/src/reactions.ts b/web/src/reactions.ts index 475b886051..5219902bbe 100644 --- a/web/src/reactions.ts +++ b/web/src/reactions.ts @@ -5,19 +5,19 @@ import {z} from "zod"; import render_message_reaction from "../templates/message_reaction.hbs"; import render_message_reactions from "../templates/message_reactions.hbs"; -import * as blueslip from "./blueslip"; -import * as channel from "./channel"; -import * as emoji from "./emoji"; -import type {EmojiRenderingDetails} from "./emoji"; -import {$t} from "./i18n"; -import * as message_lists from "./message_lists"; -import * as message_store from "./message_store"; -import type {Message, MessageCleanReaction, RawMessage} from "./message_store"; -import {page_params} from "./page_params"; -import * as people from "./people"; -import * as spectators from "./spectators"; -import {current_user} from "./state_data"; -import {user_settings} from "./user_settings"; +import * as blueslip from "./blueslip.ts"; +import * as channel from "./channel.ts"; +import * as emoji from "./emoji.ts"; +import type {EmojiRenderingDetails} from "./emoji.ts"; +import {$t} from "./i18n.ts"; +import * as message_lists from "./message_lists.ts"; +import * as message_store from "./message_store.ts"; +import type {Message, MessageCleanReaction, RawMessage} from "./message_store.ts"; +import {page_params} from "./page_params.ts"; +import * as people from "./people.ts"; +import * as spectators from "./spectators.ts"; +import {current_user} from "./state_data.ts"; +import {user_settings} from "./user_settings.ts"; const waiting_for_server_request_ids = new Set(); diff --git a/web/src/read_receipts.ts b/web/src/read_receipts.ts index 601a27b778..bb05b55bac 100644 --- a/web/src/read_receipts.ts +++ b/web/src/read_receipts.ts @@ -6,14 +6,14 @@ import {z} from "zod"; import render_read_receipts from "../templates/read_receipts.hbs"; import render_read_receipts_modal from "../templates/read_receipts_modal.hbs"; -import * as channel from "./channel"; -import {$t, $t_html} from "./i18n"; -import * as loading from "./loading"; -import * as message_store from "./message_store"; -import * as modals from "./modals"; -import * as people from "./people"; -import * as ui_report from "./ui_report"; -import * as util from "./util"; +import * as channel from "./channel.ts"; +import {$t, $t_html} from "./i18n.ts"; +import * as loading from "./loading.ts"; +import * as message_store from "./message_store.ts"; +import * as modals from "./modals.ts"; +import * as people from "./people.ts"; +import * as ui_report from "./ui_report.ts"; +import * as util from "./util.ts"; const read_receipts_api_response_schema = z.object({ user_ids: z.array(z.number()), diff --git a/web/src/realm_icon.ts b/web/src/realm_icon.ts index eb6341f580..cddf9de903 100644 --- a/web/src/realm_icon.ts +++ b/web/src/realm_icon.ts @@ -1,9 +1,9 @@ import $ from "jquery"; -import * as channel from "./channel"; -import {current_user, realm} from "./state_data"; -import * as upload_widget from "./upload_widget"; -import type {UploadFunction} from "./upload_widget"; +import * as channel from "./channel.ts"; +import {current_user, realm} from "./state_data.ts"; +import * as upload_widget from "./upload_widget.ts"; +import type {UploadFunction} from "./upload_widget.ts"; export function build_realm_icon_widget(upload_function: UploadFunction): void { const get_file_input = function (): JQuery { diff --git a/web/src/realm_logo.ts b/web/src/realm_logo.ts index e24bc1f298..acd3634c4c 100644 --- a/web/src/realm_logo.ts +++ b/web/src/realm_logo.ts @@ -1,11 +1,11 @@ import $ from "jquery"; -import * as channel from "./channel"; -import * as settings_data from "./settings_data"; -import {current_user, realm} from "./state_data"; -import * as ui_util from "./ui_util"; -import * as upload_widget from "./upload_widget"; -import type {UploadFunction} from "./upload_widget"; +import * as channel from "./channel.ts"; +import * as settings_data from "./settings_data.ts"; +import {current_user, realm} from "./state_data.ts"; +import * as ui_util from "./ui_util.ts"; +import * as upload_widget from "./upload_widget.ts"; +import type {UploadFunction} from "./upload_widget.ts"; export function build_realm_logo_widget(upload_function: UploadFunction, is_night: boolean): void { let logo_section_id = "#realm-day-logo-upload-widget"; diff --git a/web/src/realm_playground.ts b/web/src/realm_playground.ts index f332f5a662..af593a6367 100644 --- a/web/src/realm_playground.ts +++ b/web/src/realm_playground.ts @@ -1,9 +1,9 @@ import assert from "minimalistic-assert"; -import * as typeahead from "../shared/src/typeahead"; +import * as typeahead from "../shared/src/typeahead.ts"; -import {$t} from "./i18n"; -import * as pygments_data from "./pygments_data"; +import {$t} from "./i18n.ts"; +import * as pygments_data from "./pygments_data.ts"; export type RealmPlayground = { id: number; diff --git a/web/src/realm_user_settings_defaults.ts b/web/src/realm_user_settings_defaults.ts index 43d52ee401..56102cb56b 100644 --- a/web/src/realm_user_settings_defaults.ts +++ b/web/src/realm_user_settings_defaults.ts @@ -1,6 +1,6 @@ import {z} from "zod"; -import type {StateData} from "./state_data"; +import type {StateData} from "./state_data.ts"; export const realm_default_settings_schema = z.object({ allow_private_data_export: z.boolean(), diff --git a/web/src/recent_senders.ts b/web/src/recent_senders.ts index b3961e1bba..361a4cfb7d 100644 --- a/web/src/recent_senders.ts +++ b/web/src/recent_senders.ts @@ -1,9 +1,9 @@ import _ from "lodash"; -import {FoldDict} from "./fold_dict"; -import * as message_store from "./message_store"; -import * as people from "./people"; -import type {User} from "./people"; +import {FoldDict} from "./fold_dict.ts"; +import * as message_store from "./message_store.ts"; +import * as people from "./people.ts"; +import type {User} from "./people.ts"; // This class is only exported for unit testing purposes. // If we find reuse opportunities, we should just put it into diff --git a/web/src/recent_view_data.ts b/web/src/recent_view_data.ts index 9f862d2205..d5b6a24038 100644 --- a/web/src/recent_view_data.ts +++ b/web/src/recent_view_data.ts @@ -1,6 +1,6 @@ -import type {Message} from "./message_store"; -import * as people from "./people"; -import {get_key_from_message} from "./recent_view_util"; +import type {Message} from "./message_store.ts"; +import * as people from "./people.ts"; +import {get_key_from_message} from "./recent_view_util.ts"; export type ConversationData = { last_msg_id: number; diff --git a/web/src/recent_view_ui.ts b/web/src/recent_view_ui.ts index 42a83535f1..a0ea6d05d4 100644 --- a/web/src/recent_view_ui.ts +++ b/web/src/recent_view_ui.ts @@ -4,48 +4,48 @@ import assert from "minimalistic-assert"; import type * as tippy from "tippy.js"; import {z} from "zod"; -import * as typeahead from "../shared/src/typeahead"; +import * as typeahead from "../shared/src/typeahead.ts"; import render_introduce_zulip_view_modal from "../templates/introduce_zulip_view_modal.hbs"; import render_recent_view_filters from "../templates/recent_view_filters.hbs"; import render_recent_view_row from "../templates/recent_view_row.hbs"; import render_recent_view_body from "../templates/recent_view_table.hbs"; import render_user_with_status_icon from "../templates/user_with_status_icon.hbs"; -import * as blueslip from "./blueslip"; -import * as buddy_data from "./buddy_data"; -import * as compose_closed_ui from "./compose_closed_ui"; -import * as dialog_widget from "./dialog_widget"; -import * as dropdown_widget from "./dropdown_widget"; -import type {DropdownWidget} from "./dropdown_widget"; -import * as hash_util from "./hash_util"; -import {$t, $t_html} from "./i18n"; -import * as left_sidebar_navigation_area from "./left_sidebar_navigation_area"; -import * as list_widget from "./list_widget"; -import type {ListWidget} from "./list_widget"; -import * as loading from "./loading"; -import {localstorage} from "./localstorage"; -import type {MessageListData} from "./message_list_data"; -import * as message_store from "./message_store"; -import type {DisplayRecipientUser, Message} from "./message_store"; -import * as message_util from "./message_util"; -import * as muted_users from "./muted_users"; -import * as onboarding_steps from "./onboarding_steps"; -import {page_params} from "./page_params"; -import * as people from "./people"; -import * as recent_senders from "./recent_senders"; -import * as recent_view_data from "./recent_view_data"; -import type {ConversationData} from "./recent_view_data"; -import * as recent_view_util from "./recent_view_util"; -import * as stream_data from "./stream_data"; -import * as sub_store from "./sub_store"; -import * as timerender from "./timerender"; -import * as ui_util from "./ui_util"; -import * as unread from "./unread"; -import {user_settings} from "./user_settings"; -import * as user_status from "./user_status"; -import * as user_topics from "./user_topics"; -import * as util from "./util"; -import * as views_util from "./views_util"; +import * as blueslip from "./blueslip.ts"; +import * as buddy_data from "./buddy_data.ts"; +import * as compose_closed_ui from "./compose_closed_ui.ts"; +import * as dialog_widget from "./dialog_widget.ts"; +import * as dropdown_widget from "./dropdown_widget.ts"; +import type {DropdownWidget} from "./dropdown_widget.ts"; +import * as hash_util from "./hash_util.ts"; +import {$t, $t_html} from "./i18n.ts"; +import * as left_sidebar_navigation_area from "./left_sidebar_navigation_area.ts"; +import * as list_widget from "./list_widget.ts"; +import type {ListWidget} from "./list_widget.ts"; +import * as loading from "./loading.ts"; +import {localstorage} from "./localstorage.ts"; +import type {MessageListData} from "./message_list_data.ts"; +import * as message_store from "./message_store.ts"; +import type {DisplayRecipientUser, Message} from "./message_store.ts"; +import * as message_util from "./message_util.ts"; +import * as muted_users from "./muted_users.ts"; +import * as onboarding_steps from "./onboarding_steps.ts"; +import {page_params} from "./page_params.ts"; +import * as people from "./people.ts"; +import * as recent_senders from "./recent_senders.ts"; +import * as recent_view_data from "./recent_view_data.ts"; +import type {ConversationData} from "./recent_view_data.ts"; +import * as recent_view_util from "./recent_view_util.ts"; +import * as stream_data from "./stream_data.ts"; +import * as sub_store from "./sub_store.ts"; +import * as timerender from "./timerender.ts"; +import * as ui_util from "./ui_util.ts"; +import * as unread from "./unread.ts"; +import {user_settings} from "./user_settings.ts"; +import * as user_status from "./user_status.ts"; +import * as user_topics from "./user_topics.ts"; +import * as util from "./util.ts"; +import * as views_util from "./views_util.ts"; type Row = { last_msg_id: number; diff --git a/web/src/recent_view_util.ts b/web/src/recent_view_util.ts index 43cbed4a32..432539ce1e 100644 --- a/web/src/recent_view_util.ts +++ b/web/src/recent_view_util.ts @@ -1,4 +1,4 @@ -import type {Message} from "./message_store"; +import type {Message} from "./message_store.ts"; let is_view_visible = false; diff --git a/web/src/reload.ts b/web/src/reload.ts index 87af6ff7c3..107195bdde 100644 --- a/web/src/reload.ts +++ b/web/src/reload.ts @@ -2,18 +2,18 @@ import $ from "jquery"; import assert from "minimalistic-assert"; import {z} from "zod"; -import * as blueslip from "./blueslip"; -import * as compose_state from "./compose_state"; -import {csrf_token} from "./csrf"; -import * as drafts from "./drafts"; -import * as hash_util from "./hash_util"; -import type {LocalStorage} from "./localstorage"; -import {localstorage} from "./localstorage"; -import * as message_lists from "./message_lists"; -import {page_params} from "./page_params"; -import * as reload_state from "./reload_state"; -import * as ui_report from "./ui_report"; -import * as util from "./util"; +import * as blueslip from "./blueslip.ts"; +import * as compose_state from "./compose_state.ts"; +import {csrf_token} from "./csrf.ts"; +import * as drafts from "./drafts.ts"; +import * as hash_util from "./hash_util.ts"; +import type {LocalStorage} from "./localstorage.ts"; +import {localstorage} from "./localstorage.ts"; +import * as message_lists from "./message_lists.ts"; +import {page_params} from "./page_params.ts"; +import * as reload_state from "./reload_state.ts"; +import * as ui_report from "./ui_report.ts"; +import * as util from "./util.ts"; // Read https://zulip.readthedocs.io/en/latest/subsystems/hashchange-system.html diff --git a/web/src/reload_setup.js b/web/src/reload_setup.js index 6649e6b99c..799e9505d6 100644 --- a/web/src/reload_setup.js +++ b/web/src/reload_setup.js @@ -1,10 +1,10 @@ -import * as activity from "./activity"; -import * as blueslip from "./blueslip"; -import * as compose from "./compose"; -import * as compose_actions from "./compose_actions"; -import {localstorage} from "./localstorage"; -import * as message_fetch from "./message_fetch"; -import * as message_view from "./message_view"; +import * as activity from "./activity.ts"; +import * as blueslip from "./blueslip.ts"; +import * as compose from "./compose.js"; +import * as compose_actions from "./compose_actions.ts"; +import {localstorage} from "./localstorage.ts"; +import * as message_fetch from "./message_fetch.ts"; +import * as message_view from "./message_view.ts"; // Check if we're doing a compose-preserving reload. This must be // done before the first call to get_events diff --git a/web/src/rendered_markdown.ts b/web/src/rendered_markdown.ts index 1a20b64dc4..26dc65156f 100644 --- a/web/src/rendered_markdown.ts +++ b/web/src/rendered_markdown.ts @@ -7,20 +7,20 @@ import code_buttons_container from "../templates/code_buttons_container.hbs"; import render_markdown_timestamp from "../templates/markdown_timestamp.hbs"; import render_mention_content_wrapper from "../templates/mention_content_wrapper.hbs"; -import * as blueslip from "./blueslip"; -import {show_copied_confirmation} from "./copied_tooltip"; -import {$t} from "./i18n"; -import * as message_store from "./message_store"; -import type {Message} from "./message_store"; -import * as people from "./people"; -import * as realm_playground from "./realm_playground"; -import * as rows from "./rows"; -import * as rtl from "./rtl"; -import * as sub_store from "./sub_store"; -import * as timerender from "./timerender"; -import * as user_groups from "./user_groups"; -import {user_settings} from "./user_settings"; -import * as util from "./util"; +import * as blueslip from "./blueslip.ts"; +import {show_copied_confirmation} from "./copied_tooltip.ts"; +import {$t} from "./i18n.ts"; +import * as message_store from "./message_store.ts"; +import type {Message} from "./message_store.ts"; +import * as people from "./people.ts"; +import * as realm_playground from "./realm_playground.ts"; +import * as rows from "./rows.ts"; +import * as rtl from "./rtl.ts"; +import * as sub_store from "./sub_store.ts"; +import * as timerender from "./timerender.ts"; +import * as user_groups from "./user_groups.ts"; +import {user_settings} from "./user_settings.ts"; +import * as util from "./util.ts"; /* rendered_markdown diff --git a/web/src/resize.ts b/web/src/resize.ts index 53b12e694a..e0332a5451 100644 --- a/web/src/resize.ts +++ b/web/src/resize.ts @@ -2,10 +2,10 @@ import autosize from "autosize"; import $ from "jquery"; import assert from "minimalistic-assert"; -import * as blueslip from "./blueslip"; -import * as compose_state from "./compose_state"; -import * as compose_ui from "./compose_ui"; -import * as message_viewport from "./message_viewport"; +import * as blueslip from "./blueslip.ts"; +import * as compose_state from "./compose_state.ts"; +import * as compose_ui from "./compose_ui.ts"; +import * as message_viewport from "./message_viewport.ts"; function get_bottom_whitespace_height(): number { return message_viewport.height() * 0.4; diff --git a/web/src/resize_handler.ts b/web/src/resize_handler.ts index 67a24e98a7..e205310991 100644 --- a/web/src/resize_handler.ts +++ b/web/src/resize_handler.ts @@ -1,13 +1,13 @@ import $ from "jquery"; -import * as compose_ui from "./compose_ui"; -import * as condense from "./condense"; -import * as message_lists from "./message_lists"; -import * as message_viewport from "./message_viewport"; -import * as resize from "./resize"; -import * as scroll_bar from "./scroll_bar"; -import * as sidebar_ui from "./sidebar_ui"; -import * as util from "./util"; +import * as compose_ui from "./compose_ui.ts"; +import * as condense from "./condense.ts"; +import * as message_lists from "./message_lists.ts"; +import * as message_viewport from "./message_viewport.ts"; +import * as resize from "./resize.ts"; +import * as scroll_bar from "./scroll_bar.ts"; +import * as sidebar_ui from "./sidebar_ui.ts"; +import * as util from "./util.ts"; export let _old_width = $(window).width(); diff --git a/web/src/rows.ts b/web/src/rows.ts index fc56ab0ce0..ecad7cf4ba 100644 --- a/web/src/rows.ts +++ b/web/src/rows.ts @@ -1,10 +1,10 @@ import $ from "jquery"; import assert from "minimalistic-assert"; -import * as blueslip from "./blueslip"; -import * as message_lists from "./message_lists"; -import * as message_store from "./message_store"; -import type {Message} from "./message_store"; +import * as blueslip from "./blueslip.ts"; +import * as message_lists from "./message_lists.ts"; +import * as message_store from "./message_store.ts"; +import type {Message} from "./message_store.ts"; // We don't need an andSelf() here because we already know // that our next element is *not* a message_row, so this diff --git a/web/src/saved_snippets.ts b/web/src/saved_snippets.ts index 4306150b1c..08cee0bb3c 100644 --- a/web/src/saved_snippets.ts +++ b/web/src/saved_snippets.ts @@ -1,8 +1,8 @@ -import * as blueslip from "./blueslip"; -import type {Option} from "./dropdown_widget"; -import {$t} from "./i18n"; -import type {StateData} from "./state_data"; -import * as util from "./util"; +import * as blueslip from "./blueslip.ts"; +import type {Option} from "./dropdown_widget.ts"; +import {$t} from "./i18n.ts"; +import type {StateData} from "./state_data.ts"; +import * as util from "./util.ts"; export type SavedSnippet = { id: number; diff --git a/web/src/saved_snippets_ui.ts b/web/src/saved_snippets_ui.ts index 6d89255846..442a260468 100644 --- a/web/src/saved_snippets_ui.ts +++ b/web/src/saved_snippets_ui.ts @@ -5,16 +5,16 @@ import type * as tippy from "tippy.js"; import render_add_saved_snippet_modal from "../templates/add_saved_snippet_modal.hbs"; import render_confirm_delete_saved_snippet from "../templates/confirm_dialog/confirm_delete_saved_snippet.hbs"; -import * as channel from "./channel"; -import * as compose_state from "./compose_state"; -import * as compose_ui from "./compose_ui"; -import * as confirm_dialog from "./confirm_dialog"; -import * as dialog_widget from "./dialog_widget"; -import * as dropdown_widget from "./dropdown_widget"; -import {$t_html} from "./i18n"; -import * as popover_menus from "./popover_menus"; -import * as saved_snippets from "./saved_snippets"; -import type {StateData} from "./state_data"; +import * as channel from "./channel.ts"; +import * as compose_state from "./compose_state.ts"; +import * as compose_ui from "./compose_ui.ts"; +import * as confirm_dialog from "./confirm_dialog.ts"; +import * as dialog_widget from "./dialog_widget.ts"; +import * as dropdown_widget from "./dropdown_widget.ts"; +import {$t_html} from "./i18n.ts"; +import * as popover_menus from "./popover_menus.ts"; +import * as saved_snippets from "./saved_snippets.ts"; +import type {StateData} from "./state_data.ts"; let saved_snippet_dropdown_widget: dropdown_widget.DropdownWidget; diff --git a/web/src/scheduled_messages.ts b/web/src/scheduled_messages.ts index 4af844552e..6a6e4492d1 100644 --- a/web/src/scheduled_messages.ts +++ b/web/src/scheduled_messages.ts @@ -1,9 +1,9 @@ import type {z} from "zod"; -import * as channel from "./channel"; -import {$t} from "./i18n"; -import type {StateData, scheduled_message_schema} from "./state_data"; -import * as timerender from "./timerender"; +import * as channel from "./channel.ts"; +import {$t} from "./i18n.ts"; +import type {StateData, scheduled_message_schema} from "./state_data.ts"; +import * as timerender from "./timerender.ts"; export type ScheduledMessage = z.infer; diff --git a/web/src/scheduled_messages_feed_ui.ts b/web/src/scheduled_messages_feed_ui.ts index a4acbb742d..47d04784b9 100644 --- a/web/src/scheduled_messages_feed_ui.ts +++ b/web/src/scheduled_messages_feed_ui.ts @@ -2,10 +2,10 @@ import $ from "jquery"; import render_scheduled_messages_indicator from "../templates/scheduled_messages_indicator.hbs"; -import * as narrow_state from "./narrow_state"; -import * as scheduled_messages from "./scheduled_messages"; -import type {ScheduledMessage} from "./scheduled_messages"; -import * as util from "./util"; +import * as narrow_state from "./narrow_state.ts"; +import * as scheduled_messages from "./scheduled_messages.ts"; +import type {ScheduledMessage} from "./scheduled_messages.ts"; +import * as util from "./util.ts"; function get_scheduled_messages_matching_narrow(): ScheduledMessage[] { const scheduled_messages_list = [...scheduled_messages.scheduled_messages_data.values()]; diff --git a/web/src/scheduled_messages_overlay_ui.ts b/web/src/scheduled_messages_overlay_ui.ts index fc16ce67d2..592d45943b 100644 --- a/web/src/scheduled_messages_overlay_ui.ts +++ b/web/src/scheduled_messages_overlay_ui.ts @@ -4,17 +4,17 @@ import assert from "minimalistic-assert"; import render_scheduled_message from "../templates/scheduled_message.hbs"; import render_scheduled_messages_overlay from "../templates/scheduled_messages_overlay.hbs"; -import * as browser_history from "./browser_history"; -import * as messages_overlay_ui from "./messages_overlay_ui"; -import * as overlays from "./overlays"; -import * as people from "./people"; -import * as scheduled_messages from "./scheduled_messages"; -import type {ScheduledMessage} from "./scheduled_messages"; -import * as scheduled_messages_ui from "./scheduled_messages_ui"; -import * as stream_color from "./stream_color"; -import * as stream_data from "./stream_data"; -import * as sub_store from "./sub_store"; -import * as timerender from "./timerender"; +import * as browser_history from "./browser_history.ts"; +import * as messages_overlay_ui from "./messages_overlay_ui.ts"; +import * as overlays from "./overlays.ts"; +import * as people from "./people.ts"; +import * as scheduled_messages from "./scheduled_messages.ts"; +import type {ScheduledMessage} from "./scheduled_messages.ts"; +import * as scheduled_messages_ui from "./scheduled_messages_ui.ts"; +import * as stream_color from "./stream_color.ts"; +import * as stream_data from "./stream_data.ts"; +import * as sub_store from "./sub_store.ts"; +import * as timerender from "./timerender.ts"; type ScheduledMessageRenderContext = ScheduledMessage & ( diff --git a/web/src/scheduled_messages_ui.ts b/web/src/scheduled_messages_ui.ts index 61df0d2337..6d8911cd9c 100644 --- a/web/src/scheduled_messages_ui.ts +++ b/web/src/scheduled_messages_ui.ts @@ -3,14 +3,14 @@ import assert from "minimalistic-assert"; import render_compose_banner from "../templates/compose_banner/compose_banner.hbs"; -import * as compose_actions from "./compose_actions"; -import * as compose_banner from "./compose_banner"; -import {$t} from "./i18n"; -import * as message_view from "./message_view"; -import * as people from "./people"; -import * as scheduled_messages from "./scheduled_messages"; -import type {ScheduledMessage} from "./scheduled_messages"; -import * as timerender from "./timerender"; +import * as compose_actions from "./compose_actions.ts"; +import * as compose_banner from "./compose_banner.ts"; +import {$t} from "./i18n.ts"; +import * as message_view from "./message_view.ts"; +import * as people from "./people.ts"; +import * as scheduled_messages from "./scheduled_messages.ts"; +import type {ScheduledMessage} from "./scheduled_messages.ts"; +import * as timerender from "./timerender.ts"; type ScheduledMessageComposeArgs = | { diff --git a/web/src/scroll_bar.ts b/web/src/scroll_bar.ts index c2296d53b3..8e4b692df6 100644 --- a/web/src/scroll_bar.ts +++ b/web/src/scroll_bar.ts @@ -1,6 +1,6 @@ import $ from "jquery"; -import {user_settings} from "./user_settings"; +import {user_settings} from "./user_settings.ts"; export function set_layout_width(): void { if (user_settings.fluid_layout_width) { diff --git a/web/src/scroll_util.ts b/web/src/scroll_util.ts index a2446d6d4d..1d85821720 100644 --- a/web/src/scroll_util.ts +++ b/web/src/scroll_util.ts @@ -1,7 +1,7 @@ import $ from "jquery"; import SimpleBar from "simplebar"; -import * as util from "./util"; +import * as util from "./util.ts"; // This type is helpful for testing, where we may have a dummy object instead of an actual jquery object. type JQueryOrZJQuery = {__zjquery?: true} & JQuery; diff --git a/web/src/search.ts b/web/src/search.ts index 92dfb8b66a..794cccfc81 100644 --- a/web/src/search.ts +++ b/web/src/search.ts @@ -3,17 +3,17 @@ import assert from "minimalistic-assert"; import render_search_list_item from "../templates/search_list_item.hbs"; -import {Typeahead} from "./bootstrap_typeahead"; -import type {TypeaheadInputElement} from "./bootstrap_typeahead"; -import {Filter} from "./filter"; -import * as keydown_util from "./keydown_util"; -import * as narrow_state from "./narrow_state"; -import * as popovers from "./popovers"; -import * as search_pill from "./search_pill"; -import type {SearchPillWidget} from "./search_pill"; -import * as search_suggestion from "./search_suggestion"; -import type {NarrowTerm} from "./state_data"; -import * as util from "./util"; +import {Typeahead} from "./bootstrap_typeahead.ts"; +import type {TypeaheadInputElement} from "./bootstrap_typeahead.ts"; +import {Filter} from "./filter.ts"; +import * as keydown_util from "./keydown_util.ts"; +import * as narrow_state from "./narrow_state.ts"; +import * as popovers from "./popovers.ts"; +import * as search_pill from "./search_pill.ts"; +import type {SearchPillWidget} from "./search_pill.ts"; +import * as search_suggestion from "./search_suggestion.ts"; +import type {NarrowTerm} from "./state_data.ts"; +import * as util from "./util.ts"; // Exported for unit testing export let is_using_input_method = false; diff --git a/web/src/search_pill.ts b/web/src/search_pill.ts index 6f1fd52a9b..a8afce39f6 100644 --- a/web/src/search_pill.ts +++ b/web/src/search_pill.ts @@ -4,16 +4,16 @@ import assert from "minimalistic-assert"; import render_input_pill from "../templates/input_pill.hbs"; import render_search_user_pill from "../templates/search_user_pill.hbs"; -import {Filter} from "./filter"; -import * as input_pill from "./input_pill"; -import type {InputPill, InputPillContainer} from "./input_pill"; -import * as people from "./people"; -import type {User} from "./people"; -import type {NarrowTerm} from "./state_data"; -import * as stream_data from "./stream_data"; -import * as user_status from "./user_status"; -import type {UserStatusEmojiInfo} from "./user_status"; -import * as util from "./util"; +import {Filter} from "./filter.ts"; +import * as input_pill from "./input_pill.ts"; +import type {InputPill, InputPillContainer} from "./input_pill.ts"; +import * as people from "./people.ts"; +import type {User} from "./people.ts"; +import type {NarrowTerm} from "./state_data.ts"; +import * as stream_data from "./stream_data.ts"; +import * as user_status from "./user_status.ts"; +import type {UserStatusEmojiInfo} from "./user_status.ts"; +import * as util from "./util.ts"; export type SearchUserPill = { type: "search_user"; diff --git a/web/src/search_suggestion.ts b/web/src/search_suggestion.ts index d8075e20bb..9d37c6e742 100644 --- a/web/src/search_suggestion.ts +++ b/web/src/search_suggestion.ts @@ -1,21 +1,21 @@ -import Handlebars from "handlebars/runtime"; +import Handlebars from "handlebars/runtime.js"; import assert from "minimalistic-assert"; import render_user_pill from "../templates/user_pill.hbs"; -import {MAX_ITEMS} from "./bootstrap_typeahead"; -import * as common from "./common"; -import * as direct_message_group_data from "./direct_message_group_data"; -import {Filter, create_user_pill_context} from "./filter"; -import * as narrow_state from "./narrow_state"; -import {page_params} from "./page_params"; -import * as people from "./people"; -import type {User} from "./people"; -import {type NarrowTerm, current_user} from "./state_data"; -import * as stream_data from "./stream_data"; -import * as stream_topic_history from "./stream_topic_history"; -import * as stream_topic_history_util from "./stream_topic_history_util"; -import * as typeahead_helper from "./typeahead_helper"; +import {MAX_ITEMS} from "./bootstrap_typeahead.ts"; +import * as common from "./common.ts"; +import * as direct_message_group_data from "./direct_message_group_data.ts"; +import {Filter, create_user_pill_context} from "./filter.ts"; +import * as narrow_state from "./narrow_state.ts"; +import {page_params} from "./page_params.ts"; +import * as people from "./people.ts"; +import type {User} from "./people.ts"; +import {type NarrowTerm, current_user} from "./state_data.ts"; +import * as stream_data from "./stream_data.ts"; +import * as stream_topic_history from "./stream_topic_history.ts"; +import * as stream_topic_history_util from "./stream_topic_history_util.ts"; +import * as typeahead_helper from "./typeahead_helper.ts"; export type UserPillItem = { id: number; diff --git a/web/src/sent_messages.ts b/web/src/sent_messages.ts index 8780855885..a6b77be15b 100644 --- a/web/src/sent_messages.ts +++ b/web/src/sent_messages.ts @@ -1,6 +1,6 @@ import * as Sentry from "@sentry/browser"; -import * as blueslip from "./blueslip"; +import * as blueslip from "./blueslip.ts"; export let next_local_id = 0; export const messages = new Map(); diff --git a/web/src/server_events.js b/web/src/server_events.js index d7ca38a9bf..e679711ff6 100644 --- a/web/src/server_events.js +++ b/web/src/server_events.js @@ -1,19 +1,19 @@ import $ from "jquery"; import _ from "lodash"; -import * as blueslip from "./blueslip"; -import * as channel from "./channel"; -import * as echo from "./echo"; -import * as loading from "./loading"; -import * as message_events from "./message_events"; -import {page_params} from "./page_params"; -import * as reload from "./reload"; -import * as reload_state from "./reload_state"; -import * as sent_messages from "./sent_messages"; -import * as server_events_dispatch from "./server_events_dispatch"; -import {server_message_schema} from "./server_message"; -import * as ui_report from "./ui_report"; -import * as watchdog from "./watchdog"; +import * as blueslip from "./blueslip.ts"; +import * as channel from "./channel.ts"; +import * as echo from "./echo.ts"; +import * as loading from "./loading.ts"; +import * as message_events from "./message_events.js"; +import {page_params} from "./page_params.ts"; +import * as reload from "./reload.ts"; +import * as reload_state from "./reload_state.ts"; +import * as sent_messages from "./sent_messages.ts"; +import * as server_events_dispatch from "./server_events_dispatch.js"; +import {server_message_schema} from "./server_message.ts"; +import * as ui_report from "./ui_report.ts"; +import * as watchdog from "./watchdog.ts"; // Docs: https://zulip.readthedocs.io/en/latest/subsystems/events-system.html diff --git a/web/src/server_events_dispatch.js b/web/src/server_events_dispatch.js index 7f99f99a1d..1d0ee10a65 100644 --- a/web/src/server_events_dispatch.js +++ b/web/src/server_events_dispatch.js @@ -1,97 +1,97 @@ import $ from "jquery"; import assert from "minimalistic-assert"; -import * as activity_ui from "./activity_ui"; -import * as alert_words from "./alert_words"; -import * as alert_words_ui from "./alert_words_ui"; -import * as attachments_ui from "./attachments_ui"; -import * as audible_notifications from "./audible_notifications"; -import * as blueslip from "./blueslip"; -import * as bot_data from "./bot_data"; -import * as browser_history from "./browser_history"; -import {buddy_list} from "./buddy_list"; -import * as compose_call from "./compose_call"; -import * as compose_call_ui from "./compose_call_ui"; -import * as compose_closed_ui from "./compose_closed_ui"; -import * as compose_pm_pill from "./compose_pm_pill"; -import * as compose_recipient from "./compose_recipient"; -import * as compose_state from "./compose_state"; -import {electron_bridge} from "./electron_bridge"; -import * as emoji from "./emoji"; -import * as emoji_picker from "./emoji_picker"; -import * as gear_menu from "./gear_menu"; -import * as giphy from "./giphy"; -import * as information_density from "./information_density"; -import * as left_sidebar_navigation_area from "./left_sidebar_navigation_area"; -import * as linkifiers from "./linkifiers"; -import * as message_edit from "./message_edit"; -import * as message_events from "./message_events"; -import * as message_lists from "./message_lists"; -import * as message_live_update from "./message_live_update"; -import * as message_view_header from "./message_view_header"; -import * as muted_users_ui from "./muted_users_ui"; -import * as narrow_state from "./narrow_state"; -import * as narrow_title from "./narrow_title"; -import * as navbar_alerts from "./navbar_alerts"; -import * as onboarding_steps from "./onboarding_steps"; -import * as overlays from "./overlays"; -import * as peer_data from "./peer_data"; -import * as people from "./people"; -import * as pm_list from "./pm_list"; -import * as reactions from "./reactions"; -import * as realm_icon from "./realm_icon"; -import * as realm_logo from "./realm_logo"; -import * as realm_playground from "./realm_playground"; -import {realm_user_settings_defaults} from "./realm_user_settings_defaults"; -import * as reload from "./reload"; -import * as saved_snippets from "./saved_snippets"; -import * as saved_snippets_ui from "./saved_snippets_ui"; -import * as scheduled_messages from "./scheduled_messages"; -import * as scheduled_messages_feed_ui from "./scheduled_messages_feed_ui"; -import * as scheduled_messages_overlay_ui from "./scheduled_messages_overlay_ui"; -import * as scheduled_messages_ui from "./scheduled_messages_ui"; -import * as scroll_bar from "./scroll_bar"; -import * as settings_account from "./settings_account"; -import * as settings_bots from "./settings_bots"; -import * as settings_components from "./settings_components"; -import * as settings_config from "./settings_config"; -import * as settings_emoji from "./settings_emoji"; -import * as settings_exports from "./settings_exports"; -import * as settings_invites from "./settings_invites"; -import * as settings_linkifiers from "./settings_linkifiers"; -import * as settings_notifications from "./settings_notifications"; -import * as settings_org from "./settings_org"; -import * as settings_playgrounds from "./settings_playgrounds"; -import * as settings_preferences from "./settings_preferences"; -import * as settings_profile_fields from "./settings_profile_fields"; -import * as settings_realm_domains from "./settings_realm_domains"; -import * as settings_realm_user_settings_defaults from "./settings_realm_user_settings_defaults"; -import * as settings_streams from "./settings_streams"; -import * as settings_users from "./settings_users"; -import * as sidebar_ui from "./sidebar_ui"; -import * as starred_messages from "./starred_messages"; -import * as starred_messages_ui from "./starred_messages_ui"; -import {current_user, realm} from "./state_data"; -import * as stream_data from "./stream_data"; -import * as stream_events from "./stream_events"; -import * as stream_list from "./stream_list"; -import * as stream_list_sort from "./stream_list_sort"; -import * as stream_settings_ui from "./stream_settings_ui"; -import * as stream_topic_history from "./stream_topic_history"; -import * as stream_ui_updates from "./stream_ui_updates"; -import * as sub_store from "./sub_store"; -import * as submessage from "./submessage"; -import * as theme from "./theme"; -import * as typing_events from "./typing_events"; -import * as unread_ops from "./unread_ops"; -import * as unread_ui from "./unread_ui"; -import * as user_events from "./user_events"; -import * as user_group_edit from "./user_group_edit"; -import * as user_groups from "./user_groups"; -import {user_settings} from "./user_settings"; -import * as user_status from "./user_status"; -import * as user_topics from "./user_topics"; -import * as user_topics_ui from "./user_topics_ui"; +import * as activity_ui from "./activity_ui.ts"; +import * as alert_words from "./alert_words.ts"; +import * as alert_words_ui from "./alert_words_ui.ts"; +import * as attachments_ui from "./attachments_ui.ts"; +import * as audible_notifications from "./audible_notifications.ts"; +import * as blueslip from "./blueslip.ts"; +import * as bot_data from "./bot_data.ts"; +import * as browser_history from "./browser_history.ts"; +import {buddy_list} from "./buddy_list.ts"; +import * as compose_call from "./compose_call.ts"; +import * as compose_call_ui from "./compose_call_ui.ts"; +import * as compose_closed_ui from "./compose_closed_ui.ts"; +import * as compose_pm_pill from "./compose_pm_pill.ts"; +import * as compose_recipient from "./compose_recipient.ts"; +import * as compose_state from "./compose_state.ts"; +import {electron_bridge} from "./electron_bridge.ts"; +import * as emoji from "./emoji.ts"; +import * as emoji_picker from "./emoji_picker.ts"; +import * as gear_menu from "./gear_menu.js"; +import * as giphy from "./giphy.js"; +import * as information_density from "./information_density.ts"; +import * as left_sidebar_navigation_area from "./left_sidebar_navigation_area.ts"; +import * as linkifiers from "./linkifiers.ts"; +import * as message_edit from "./message_edit.ts"; +import * as message_events from "./message_events.js"; +import * as message_lists from "./message_lists.ts"; +import * as message_live_update from "./message_live_update.ts"; +import * as message_view_header from "./message_view_header.ts"; +import * as muted_users_ui from "./muted_users_ui.ts"; +import * as narrow_state from "./narrow_state.ts"; +import * as narrow_title from "./narrow_title.ts"; +import * as navbar_alerts from "./navbar_alerts.ts"; +import * as onboarding_steps from "./onboarding_steps.ts"; +import * as overlays from "./overlays.ts"; +import * as peer_data from "./peer_data.ts"; +import * as people from "./people.ts"; +import * as pm_list from "./pm_list.ts"; +import * as reactions from "./reactions.ts"; +import * as realm_icon from "./realm_icon.ts"; +import * as realm_logo from "./realm_logo.ts"; +import * as realm_playground from "./realm_playground.ts"; +import {realm_user_settings_defaults} from "./realm_user_settings_defaults.ts"; +import * as reload from "./reload.ts"; +import * as saved_snippets from "./saved_snippets.ts"; +import * as saved_snippets_ui from "./saved_snippets_ui.ts"; +import * as scheduled_messages from "./scheduled_messages.ts"; +import * as scheduled_messages_feed_ui from "./scheduled_messages_feed_ui.ts"; +import * as scheduled_messages_overlay_ui from "./scheduled_messages_overlay_ui.ts"; +import * as scheduled_messages_ui from "./scheduled_messages_ui.ts"; +import * as scroll_bar from "./scroll_bar.ts"; +import * as settings_account from "./settings_account.ts"; +import * as settings_bots from "./settings_bots.ts"; +import * as settings_components from "./settings_components.ts"; +import * as settings_config from "./settings_config.ts"; +import * as settings_emoji from "./settings_emoji.ts"; +import * as settings_exports from "./settings_exports.ts"; +import * as settings_invites from "./settings_invites.ts"; +import * as settings_linkifiers from "./settings_linkifiers.ts"; +import * as settings_notifications from "./settings_notifications.ts"; +import * as settings_org from "./settings_org.ts"; +import * as settings_playgrounds from "./settings_playgrounds.ts"; +import * as settings_preferences from "./settings_preferences.ts"; +import * as settings_profile_fields from "./settings_profile_fields.ts"; +import * as settings_realm_domains from "./settings_realm_domains.ts"; +import * as settings_realm_user_settings_defaults from "./settings_realm_user_settings_defaults.ts"; +import * as settings_streams from "./settings_streams.ts"; +import * as settings_users from "./settings_users.ts"; +import * as sidebar_ui from "./sidebar_ui.ts"; +import * as starred_messages from "./starred_messages.ts"; +import * as starred_messages_ui from "./starred_messages_ui.ts"; +import {current_user, realm} from "./state_data.ts"; +import * as stream_data from "./stream_data.ts"; +import * as stream_events from "./stream_events.js"; +import * as stream_list from "./stream_list.ts"; +import * as stream_list_sort from "./stream_list_sort.ts"; +import * as stream_settings_ui from "./stream_settings_ui.js"; +import * as stream_topic_history from "./stream_topic_history.ts"; +import * as stream_ui_updates from "./stream_ui_updates.ts"; +import * as sub_store from "./sub_store.ts"; +import * as submessage from "./submessage.ts"; +import * as theme from "./theme.ts"; +import * as typing_events from "./typing_events.ts"; +import * as unread_ops from "./unread_ops.ts"; +import * as unread_ui from "./unread_ui.ts"; +import * as user_events from "./user_events.js"; +import * as user_group_edit from "./user_group_edit.js"; +import * as user_groups from "./user_groups.ts"; +import {user_settings} from "./user_settings.ts"; +import * as user_status from "./user_status.ts"; +import * as user_topics from "./user_topics.ts"; +import * as user_topics_ui from "./user_topics_ui.ts"; export function dispatch_normal_event(event) { const noop = function () {}; diff --git a/web/src/settings.js b/web/src/settings.js index de0275eee2..1c7d6653a6 100644 --- a/web/src/settings.js +++ b/web/src/settings.js @@ -5,24 +5,24 @@ import timezones from "../generated/timezones.json"; import render_settings_overlay from "../templates/settings_overlay.hbs"; import render_settings_tab from "../templates/settings_tab.hbs"; -import * as browser_history from "./browser_history"; -import * as common from "./common"; -import * as flatpickr from "./flatpickr"; -import {$t} from "./i18n"; -import * as modals from "./modals"; -import * as overlays from "./overlays"; -import {page_params} from "./page_params"; -import * as people from "./people"; -import * as settings_bots from "./settings_bots"; -import * as settings_config from "./settings_config"; -import * as settings_data from "./settings_data"; -import * as settings_panel_menu from "./settings_panel_menu"; -import * as settings_preferences from "./settings_preferences"; -import * as settings_sections from "./settings_sections"; -import * as settings_toggle from "./settings_toggle"; -import {current_user, realm} from "./state_data"; -import * as timerender from "./timerender"; -import {user_settings} from "./user_settings"; +import * as browser_history from "./browser_history.ts"; +import * as common from "./common.ts"; +import * as flatpickr from "./flatpickr.ts"; +import {$t} from "./i18n.ts"; +import * as modals from "./modals.ts"; +import * as overlays from "./overlays.ts"; +import {page_params} from "./page_params.ts"; +import * as people from "./people.ts"; +import * as settings_bots from "./settings_bots.ts"; +import * as settings_config from "./settings_config.ts"; +import * as settings_data from "./settings_data.ts"; +import * as settings_panel_menu from "./settings_panel_menu.js"; +import * as settings_preferences from "./settings_preferences.ts"; +import * as settings_sections from "./settings_sections.js"; +import * as settings_toggle from "./settings_toggle.js"; +import {current_user, realm} from "./state_data.ts"; +import * as timerender from "./timerender.ts"; +import {user_settings} from "./user_settings.ts"; export let settings_label; diff --git a/web/src/settings_account.ts b/web/src/settings_account.ts index a06d0f8eae..7cd065c0a8 100644 --- a/web/src/settings_account.ts +++ b/web/src/settings_account.ts @@ -8,33 +8,33 @@ import render_dialog_change_password from "../templates/dialog_change_password.h import render_settings_api_key_modal from "../templates/settings/api_key_modal.hbs"; import render_settings_dev_env_email_access from "../templates/settings/dev_env_email_access.hbs"; -import * as avatar from "./avatar"; -import * as channel from "./channel"; -import * as common from "./common"; -import {csrf_token} from "./csrf"; -import * as custom_profile_fields_ui from "./custom_profile_fields_ui"; -import type {PillUpdateField} from "./custom_profile_fields_ui"; -import * as dialog_widget from "./dialog_widget"; -import {$t_html} from "./i18n"; -import * as keydown_util from "./keydown_util"; -import * as modals from "./modals"; -import * as overlays from "./overlays"; -import {page_params} from "./page_params"; -import * as people from "./people"; -import * as settings_bots from "./settings_bots"; -import * as settings_components from "./settings_components"; -import * as settings_data from "./settings_data"; -import * as settings_org from "./settings_org"; -import * as settings_ui from "./settings_ui"; -import {current_user, realm} from "./state_data"; -import * as ui_report from "./ui_report"; -import * as ui_util from "./ui_util"; -import * as user_deactivation_ui from "./user_deactivation_ui"; -import * as user_pill from "./user_pill"; -import type {UserPillWidget} from "./user_pill"; -import * as user_profile from "./user_profile"; -import {user_settings} from "./user_settings"; -import * as util from "./util"; +import * as avatar from "./avatar.ts"; +import * as channel from "./channel.ts"; +import * as common from "./common.ts"; +import {csrf_token} from "./csrf.ts"; +import * as custom_profile_fields_ui from "./custom_profile_fields_ui.ts"; +import type {PillUpdateField} from "./custom_profile_fields_ui.ts"; +import * as dialog_widget from "./dialog_widget.ts"; +import {$t_html} from "./i18n.ts"; +import * as keydown_util from "./keydown_util.ts"; +import * as modals from "./modals.ts"; +import * as overlays from "./overlays.ts"; +import {page_params} from "./page_params.ts"; +import * as people from "./people.ts"; +import * as settings_bots from "./settings_bots.ts"; +import * as settings_components from "./settings_components.ts"; +import * as settings_data from "./settings_data.ts"; +import * as settings_org from "./settings_org.ts"; +import * as settings_ui from "./settings_ui.ts"; +import {current_user, realm} from "./state_data.ts"; +import * as ui_report from "./ui_report.ts"; +import * as ui_util from "./ui_util.ts"; +import * as user_deactivation_ui from "./user_deactivation_ui.ts"; +import * as user_pill from "./user_pill.ts"; +import type {UserPillWidget} from "./user_pill.ts"; +import * as user_profile from "./user_profile.ts"; +import {user_settings} from "./user_settings.ts"; +import * as util from "./util.ts"; let password_quality: | ((password: string, $bar: JQuery | undefined, $password_field: JQuery) => boolean) diff --git a/web/src/settings_bots.ts b/web/src/settings_bots.ts index 795d36f5b7..b365dec391 100644 --- a/web/src/settings_bots.ts +++ b/web/src/settings_bots.ts @@ -7,25 +7,25 @@ import render_add_new_bot_form from "../templates/settings/add_new_bot_form.hbs" import render_bot_avatar_row from "../templates/settings/bot_avatar_row.hbs"; import render_bot_settings_tip from "../templates/settings/bot_settings_tip.hbs"; -import * as avatar from "./avatar"; -import * as bot_data from "./bot_data"; -import * as channel from "./channel"; -import * as components from "./components"; -import {show_copied_confirmation} from "./copied_tooltip"; -import {csrf_token} from "./csrf"; -import * as dialog_widget from "./dialog_widget"; -import {$t, $t_html} from "./i18n"; -import * as integration_url_modal from "./integration_url_modal"; -import * as list_widget from "./list_widget"; -import {page_params} from "./page_params"; -import * as people from "./people"; -import * as settings_data from "./settings_data"; -import {current_user, realm} from "./state_data"; -import type {HTMLSelectOneElement} from "./types"; -import * as ui_report from "./ui_report"; -import type {UploadWidget} from "./upload_widget"; -import * as user_deactivation_ui from "./user_deactivation_ui"; -import * as user_profile from "./user_profile"; +import * as avatar from "./avatar.ts"; +import * as bot_data from "./bot_data.ts"; +import * as channel from "./channel.ts"; +import * as components from "./components.ts"; +import {show_copied_confirmation} from "./copied_tooltip.ts"; +import {csrf_token} from "./csrf.ts"; +import * as dialog_widget from "./dialog_widget.ts"; +import {$t, $t_html} from "./i18n.ts"; +import * as integration_url_modal from "./integration_url_modal.ts"; +import * as list_widget from "./list_widget.ts"; +import {page_params} from "./page_params.ts"; +import * as people from "./people.ts"; +import * as settings_data from "./settings_data.ts"; +import {current_user, realm} from "./state_data.ts"; +import type {HTMLSelectOneElement} from "./types.ts"; +import * as ui_report from "./ui_report.ts"; +import type {UploadWidget} from "./upload_widget.ts"; +import * as user_deactivation_ui from "./user_deactivation_ui.ts"; +import * as user_profile from "./user_profile.ts"; const INCOMING_WEBHOOK_BOT_TYPE = 2; const OUTGOING_WEBHOOK_BOT_TYPE = "3"; diff --git a/web/src/settings_components.ts b/web/src/settings_components.ts index 6bfe911c7e..90968c2b7f 100644 --- a/web/src/settings_components.ts +++ b/web/src/settings_components.ts @@ -6,38 +6,38 @@ import {z} from "zod"; import render_compose_banner from "../templates/compose_banner/compose_banner.hbs"; -import * as blueslip from "./blueslip"; -import * as compose_banner from "./compose_banner"; -import type {DropdownWidget} from "./dropdown_widget"; -import * as group_permission_settings from "./group_permission_settings"; -import * as group_setting_pill from "./group_setting_pill"; -import {$t} from "./i18n"; +import * as blueslip from "./blueslip.ts"; +import * as compose_banner from "./compose_banner.ts"; +import type {DropdownWidget} from "./dropdown_widget.ts"; +import * as group_permission_settings from "./group_permission_settings.ts"; +import * as group_setting_pill from "./group_setting_pill.ts"; +import {$t} from "./i18n.ts"; import { LEGACY_FONT_SIZE_PX, LEGACY_LINE_HEIGHT_PERCENT, NON_COMPACT_MODE_FONT_SIZE_PX, NON_COMPACT_MODE_LINE_HEIGHT_PERCENT, -} from "./information_density"; -import * as people from "./people"; +} from "./information_density.ts"; +import * as people from "./people.ts"; import { realm_default_settings_schema, realm_user_settings_defaults, -} from "./realm_user_settings_defaults"; -import * as scroll_util from "./scroll_util"; -import * as settings_config from "./settings_config"; -import * as settings_data from "./settings_data"; -import type {CustomProfileField, GroupSettingValue} from "./state_data"; -import {current_user, group_setting_value_schema, realm, realm_schema} from "./state_data"; -import * as stream_data from "./stream_data"; -import type {StreamSubscription} from "./sub_store"; -import {stream_subscription_schema} from "./sub_store"; -import type {GroupSettingPillContainer} from "./typeahead_helper"; -import type {HTMLSelectOneElement} from "./types"; -import * as user_group_pill from "./user_group_pill"; -import * as user_groups from "./user_groups"; -import type {UserGroup} from "./user_groups"; -import * as user_pill from "./user_pill"; -import * as util from "./util"; +} from "./realm_user_settings_defaults.ts"; +import * as scroll_util from "./scroll_util.ts"; +import * as settings_config from "./settings_config.ts"; +import * as settings_data from "./settings_data.ts"; +import type {CustomProfileField, GroupSettingValue} from "./state_data.ts"; +import {current_user, group_setting_value_schema, realm, realm_schema} from "./state_data.ts"; +import * as stream_data from "./stream_data.ts"; +import type {StreamSubscription} from "./sub_store.ts"; +import {stream_subscription_schema} from "./sub_store.ts"; +import type {GroupSettingPillContainer} from "./typeahead_helper.ts"; +import type {HTMLSelectOneElement} from "./types.ts"; +import * as user_group_pill from "./user_group_pill.ts"; +import * as user_groups from "./user_groups.ts"; +import type {UserGroup} from "./user_groups.ts"; +import * as user_pill from "./user_pill.ts"; +import * as util from "./util.ts"; const MAX_CUSTOM_TIME_LIMIT_SETTING_VALUE = 2147483647; diff --git a/web/src/settings_config.ts b/web/src/settings_config.ts index a11dc95867..76aab5c44b 100644 --- a/web/src/settings_config.ts +++ b/web/src/settings_config.ts @@ -1,17 +1,17 @@ -import Handlebars from "handlebars/runtime"; +import Handlebars from "handlebars/runtime.js"; -import {page_params} from "./base_page_params"; -import {$t, $t_html} from "./i18n"; -import type {RealmDefaultSettings} from "./realm_user_settings_defaults"; -import {realm} from "./state_data"; -import {StreamPostPolicy} from "./stream_types"; -import type {StreamSpecificNotificationSettings} from "./sub_store"; +import {page_params} from "./base_page_params.ts"; +import {$t, $t_html} from "./i18n.ts"; +import type {RealmDefaultSettings} from "./realm_user_settings_defaults.ts"; +import {realm} from "./state_data.ts"; +import {StreamPostPolicy} from "./stream_types.ts"; +import type {StreamSpecificNotificationSettings} from "./sub_store.ts"; import type { FollowedTopicNotificationSettings, PmNotificationSettings, StreamNotificationSettings, UserSettings, -} from "./user_settings"; +} from "./user_settings.ts"; /* This file contains translations between the integer values used in diff --git a/web/src/settings_data.ts b/web/src/settings_data.ts index bdca2ff94d..b916e271eb 100644 --- a/web/src/settings_data.ts +++ b/web/src/settings_data.ts @@ -1,12 +1,12 @@ import assert from "minimalistic-assert"; -import * as group_permission_settings from "./group_permission_settings"; -import {page_params} from "./page_params"; -import * as settings_config from "./settings_config"; -import {current_user, realm} from "./state_data"; -import type {GroupSettingValue} from "./state_data"; -import * as user_groups from "./user_groups"; -import {user_settings} from "./user_settings"; +import * as group_permission_settings from "./group_permission_settings.ts"; +import {page_params} from "./page_params.ts"; +import * as settings_config from "./settings_config.ts"; +import {current_user, realm} from "./state_data.ts"; +import type {GroupSettingValue} from "./state_data.ts"; +import * as user_groups from "./user_groups.ts"; +import {user_settings} from "./user_settings.ts"; let user_join_date: Date; export function initialize(current_user_join_date: Date): void { diff --git a/web/src/settings_emoji.ts b/web/src/settings_emoji.ts index 4fab99a473..e66c39866c 100644 --- a/web/src/settings_emoji.ts +++ b/web/src/settings_emoji.ts @@ -7,21 +7,21 @@ import emoji_settings_warning_modal from "../templates/confirm_dialog/confirm_em import render_add_emoji from "../templates/settings/add_emoji.hbs"; import render_admin_emoji_list from "../templates/settings/admin_emoji_list.hbs"; -import * as channel from "./channel"; -import * as confirm_dialog from "./confirm_dialog"; -import * as dialog_widget from "./dialog_widget"; -import * as emoji from "./emoji"; -import type {ServerEmoji} from "./emoji"; -import {$t_html} from "./i18n"; -import * as ListWidget from "./list_widget"; -import * as loading from "./loading"; -import * as people from "./people"; -import * as scroll_util from "./scroll_util"; -import * as settings_data from "./settings_data"; -import {current_user} from "./state_data"; -import * as ui_report from "./ui_report"; -import * as upload_widget from "./upload_widget"; -import * as util from "./util"; +import * as channel from "./channel.ts"; +import * as confirm_dialog from "./confirm_dialog.ts"; +import * as dialog_widget from "./dialog_widget.ts"; +import * as emoji from "./emoji.ts"; +import type {ServerEmoji} from "./emoji.ts"; +import {$t_html} from "./i18n.ts"; +import * as ListWidget from "./list_widget.ts"; +import * as loading from "./loading.ts"; +import * as people from "./people.ts"; +import * as scroll_util from "./scroll_util.ts"; +import * as settings_data from "./settings_data.ts"; +import {current_user} from "./state_data.ts"; +import * as ui_report from "./ui_report.ts"; +import * as upload_widget from "./upload_widget.ts"; +import * as util from "./util.ts"; const meta = { loaded: false, diff --git a/web/src/settings_exports.ts b/web/src/settings_exports.ts index d61c7b1450..1f5b04ddcb 100644 --- a/web/src/settings_exports.ts +++ b/web/src/settings_exports.ts @@ -7,22 +7,22 @@ import render_admin_export_consent_list from "../templates/settings/admin_export import render_admin_export_list from "../templates/settings/admin_export_list.hbs"; import render_start_export_modal from "../templates/start_export_modal.hbs"; -import * as channel from "./channel"; -import * as components from "./components"; -import * as confirm_dialog from "./confirm_dialog"; -import * as dialog_widget from "./dialog_widget"; -import * as dropdown_widget from "./dropdown_widget"; -import type {DropdownWidget, Option} from "./dropdown_widget"; -import {$t, $t_html} from "./i18n"; -import * as ListWidget from "./list_widget"; -import type {ListWidget as ListWidgetType} from "./list_widget"; -import * as loading from "./loading"; -import * as people from "./people"; -import * as scroll_util from "./scroll_util"; -import * as settings_config from "./settings_config"; -import * as timerender from "./timerender"; -import type {HTMLSelectOneElement} from "./types"; -import * as ui_report from "./ui_report"; +import * as channel from "./channel.ts"; +import * as components from "./components.ts"; +import * as confirm_dialog from "./confirm_dialog.ts"; +import * as dialog_widget from "./dialog_widget.ts"; +import * as dropdown_widget from "./dropdown_widget.ts"; +import type {DropdownWidget, Option} from "./dropdown_widget.ts"; +import {$t, $t_html} from "./i18n.ts"; +import * as ListWidget from "./list_widget.ts"; +import type {ListWidget as ListWidgetType} from "./list_widget.ts"; +import * as loading from "./loading.ts"; +import * as people from "./people.ts"; +import * as scroll_util from "./scroll_util.ts"; +import * as settings_config from "./settings_config.ts"; +import * as timerender from "./timerender.ts"; +import type {HTMLSelectOneElement} from "./types.ts"; +import * as ui_report from "./ui_report.ts"; const export_consent_schema = z.object({ user_id: z.number(), diff --git a/web/src/settings_invites.ts b/web/src/settings_invites.ts index e885f9efca..b8c905c881 100644 --- a/web/src/settings_invites.ts +++ b/web/src/settings_invites.ts @@ -5,20 +5,20 @@ import render_settings_resend_invite_modal from "../templates/confirm_dialog/con import render_settings_revoke_invite_modal from "../templates/confirm_dialog/confirm_revoke_invite.hbs"; import render_admin_invites_list from "../templates/settings/admin_invites_list.hbs"; -import * as blueslip from "./blueslip"; -import * as channel from "./channel"; -import * as confirm_dialog from "./confirm_dialog"; -import * as dialog_widget from "./dialog_widget"; -import {$t, $t_html} from "./i18n"; -import * as ListWidget from "./list_widget"; -import * as loading from "./loading"; -import * as people from "./people"; -import * as settings_config from "./settings_config"; -import * as settings_data from "./settings_data"; -import {current_user, realm} from "./state_data"; -import * as timerender from "./timerender"; -import * as ui_report from "./ui_report"; -import * as util from "./util"; +import * as blueslip from "./blueslip.ts"; +import * as channel from "./channel.ts"; +import * as confirm_dialog from "./confirm_dialog.ts"; +import * as dialog_widget from "./dialog_widget.ts"; +import {$t, $t_html} from "./i18n.ts"; +import * as ListWidget from "./list_widget.ts"; +import * as loading from "./loading.ts"; +import * as people from "./people.ts"; +import * as settings_config from "./settings_config.ts"; +import * as settings_data from "./settings_data.ts"; +import {current_user, realm} from "./state_data.ts"; +import * as timerender from "./timerender.ts"; +import * as ui_report from "./ui_report.ts"; +import * as util from "./util.ts"; export const invite_schema = z.intersection( z.object({ diff --git a/web/src/settings_linkifiers.ts b/web/src/settings_linkifiers.ts index 74e1a8831b..a0659f5e29 100644 --- a/web/src/settings_linkifiers.ts +++ b/web/src/settings_linkifiers.ts @@ -7,17 +7,17 @@ import render_confirm_delete_linkifier from "../templates/confirm_dialog/confirm import render_admin_linkifier_edit_form from "../templates/settings/admin_linkifier_edit_form.hbs"; import render_admin_linkifier_list from "../templates/settings/admin_linkifier_list.hbs"; -import * as channel from "./channel"; -import * as confirm_dialog from "./confirm_dialog"; -import * as dialog_widget from "./dialog_widget"; -import {$t_html} from "./i18n"; -import * as ListWidget from "./list_widget"; -import * as scroll_util from "./scroll_util"; -import * as settings_ui from "./settings_ui"; -import {current_user, realm} from "./state_data"; -import * as ui_report from "./ui_report"; -import * as ui_util from "./ui_util"; -import * as util from "./util"; +import * as channel from "./channel.ts"; +import * as confirm_dialog from "./confirm_dialog.ts"; +import * as dialog_widget from "./dialog_widget.ts"; +import {$t_html} from "./i18n.ts"; +import * as ListWidget from "./list_widget.ts"; +import * as scroll_util from "./scroll_util.ts"; +import * as settings_ui from "./settings_ui.ts"; +import {current_user, realm} from "./state_data.ts"; +import * as ui_report from "./ui_report.ts"; +import * as ui_util from "./ui_util.ts"; +import * as util from "./util.ts"; type RealmLinkifiers = typeof realm.realm_linkifiers; diff --git a/web/src/settings_muted_users.ts b/web/src/settings_muted_users.ts index a43a6e8c64..36c22fb844 100644 --- a/web/src/settings_muted_users.ts +++ b/web/src/settings_muted_users.ts @@ -2,10 +2,10 @@ import $ from "jquery"; import render_muted_user_ui_row from "../templates/muted_user_ui_row.hbs"; -import * as ListWidget from "./list_widget"; -import * as muted_users from "./muted_users"; -import * as people from "./people"; -import * as scroll_util from "./scroll_util"; +import * as ListWidget from "./list_widget.ts"; +import * as muted_users from "./muted_users.ts"; +import * as people from "./people.ts"; +import * as scroll_util from "./scroll_util.ts"; export let loaded = false; diff --git a/web/src/settings_notifications.ts b/web/src/settings_notifications.ts index 83a178195a..c503a00fd0 100644 --- a/web/src/settings_notifications.ts +++ b/web/src/settings_notifications.ts @@ -5,31 +5,31 @@ import {z} from "zod"; import render_confirm_disable_all_notifications from "../templates/confirm_dialog/confirm_disable_all_notifications.hbs"; import render_stream_specific_notification_row from "../templates/settings/stream_specific_notification_row.hbs"; -import * as blueslip from "./blueslip"; -import * as channel from "./channel"; -import * as confirm_dialog from "./confirm_dialog"; -import {$t, $t_html} from "./i18n"; -import * as message_notifications from "./message_notifications"; -import {page_params} from "./page_params"; -import * as settings_components from "./settings_components"; -import * as settings_config from "./settings_config"; -import type {SettingsPanel} from "./settings_preferences"; -import * as settings_ui from "./settings_ui"; -import {realm} from "./state_data"; -import * as stream_data from "./stream_data"; -import * as stream_settings_api from "./stream_settings_api"; -import * as stream_settings_data from "./stream_settings_data"; -import {stream_specific_notification_settings_schema} from "./stream_types"; -import * as sub_store from "./sub_store"; -import type {StreamSubscription} from "./sub_store"; -import * as ui_util from "./ui_util"; -import * as unread_ui from "./unread_ui"; +import * as blueslip from "./blueslip.ts"; +import * as channel from "./channel.ts"; +import * as confirm_dialog from "./confirm_dialog.ts"; +import {$t, $t_html} from "./i18n.ts"; +import * as message_notifications from "./message_notifications.ts"; +import {page_params} from "./page_params.ts"; +import * as settings_components from "./settings_components.ts"; +import * as settings_config from "./settings_config.ts"; +import type {SettingsPanel} from "./settings_preferences.ts"; +import * as settings_ui from "./settings_ui.ts"; +import {realm} from "./state_data.ts"; +import * as stream_data from "./stream_data.ts"; +import * as stream_settings_api from "./stream_settings_api.ts"; +import * as stream_settings_data from "./stream_settings_data.ts"; +import {stream_specific_notification_settings_schema} from "./stream_types.ts"; +import * as sub_store from "./sub_store.ts"; +import type {StreamSubscription} from "./sub_store.ts"; +import * as ui_util from "./ui_util.ts"; +import * as unread_ui from "./unread_ui.ts"; import { pm_notification_settings_schema, user_settings, user_settings_schema, -} from "./user_settings"; -import * as util from "./util"; +} from "./user_settings.ts"; +import * as util from "./util.ts"; export let user_settings_panel: SettingsPanel | undefined; diff --git a/web/src/settings_org.ts b/web/src/settings_org.ts index 54bdbc0c6d..e2b5903336 100644 --- a/web/src/settings_org.ts +++ b/web/src/settings_org.ts @@ -5,19 +5,19 @@ import {z} from "zod"; import render_settings_deactivate_realm_modal from "../templates/confirm_dialog/confirm_deactivate_realm.hbs"; import render_settings_admin_auth_methods_list from "../templates/settings/admin_auth_methods_list.hbs"; -import * as audible_notifications from "./audible_notifications"; -import * as blueslip from "./blueslip"; -import * as channel from "./channel"; -import {csrf_token} from "./csrf"; -import * as dialog_widget from "./dialog_widget"; -import * as dropdown_widget from "./dropdown_widget"; -import {$t, $t_html, get_language_name} from "./i18n"; -import * as keydown_util from "./keydown_util"; -import * as loading from "./loading"; -import * as pygments_data from "./pygments_data"; -import * as realm_icon from "./realm_icon"; -import * as realm_logo from "./realm_logo"; -import {realm_user_settings_defaults} from "./realm_user_settings_defaults"; +import * as audible_notifications from "./audible_notifications.ts"; +import * as blueslip from "./blueslip.ts"; +import * as channel from "./channel.ts"; +import {csrf_token} from "./csrf.ts"; +import * as dialog_widget from "./dialog_widget.ts"; +import * as dropdown_widget from "./dropdown_widget.ts"; +import {$t, $t_html, get_language_name} from "./i18n.ts"; +import * as keydown_util from "./keydown_util.ts"; +import * as loading from "./loading.ts"; +import * as pygments_data from "./pygments_data.ts"; +import * as realm_icon from "./realm_icon.ts"; +import * as realm_logo from "./realm_logo.ts"; +import {realm_user_settings_defaults} from "./realm_user_settings_defaults.ts"; import { type MessageMoveTimeLimitSetting, type RealmGroupSettingName, @@ -27,23 +27,23 @@ import { realm_user_settings_default_properties_schema, simple_dropdown_realm_settings_schema, stream_settings_property_schema, -} from "./settings_components"; -import * as settings_components from "./settings_components"; -import * as settings_config from "./settings_config"; -import * as settings_data from "./settings_data"; -import * as settings_notifications from "./settings_notifications"; -import * as settings_preferences from "./settings_preferences"; -import * as settings_realm_domains from "./settings_realm_domains"; -import * as settings_ui from "./settings_ui"; -import {current_user, group_setting_value_schema, realm, realm_schema} from "./state_data"; -import type {Realm} from "./state_data"; -import * as stream_settings_data from "./stream_settings_data"; -import type {StreamSubscription} from "./sub_store"; -import type {HTMLSelectOneElement} from "./types"; -import * as ui_report from "./ui_report"; -import * as user_groups from "./user_groups"; -import type {UserGroup, UserGroupForDropdownListWidget} from "./user_groups"; -import * as util from "./util"; +} from "./settings_components.ts"; +import * as settings_components from "./settings_components.ts"; +import * as settings_config from "./settings_config.ts"; +import * as settings_data from "./settings_data.ts"; +import * as settings_notifications from "./settings_notifications.ts"; +import * as settings_preferences from "./settings_preferences.ts"; +import * as settings_realm_domains from "./settings_realm_domains.ts"; +import * as settings_ui from "./settings_ui.ts"; +import {current_user, group_setting_value_schema, realm, realm_schema} from "./state_data.ts"; +import type {Realm} from "./state_data.ts"; +import * as stream_settings_data from "./stream_settings_data.ts"; +import type {StreamSubscription} from "./sub_store.ts"; +import type {HTMLSelectOneElement} from "./types.ts"; +import * as ui_report from "./ui_report.ts"; +import * as user_groups from "./user_groups.ts"; +import type {UserGroup, UserGroupForDropdownListWidget} from "./user_groups.ts"; +import * as util from "./util.ts"; const meta = { loaded: false, diff --git a/web/src/settings_panel_menu.js b/web/src/settings_panel_menu.js index c8ad649e95..918d0491bd 100644 --- a/web/src/settings_panel_menu.js +++ b/web/src/settings_panel_menu.js @@ -1,14 +1,14 @@ import $ from "jquery"; -import * as blueslip from "./blueslip"; -import * as browser_history from "./browser_history"; -import * as components from "./components"; -import {$t, $t_html} from "./i18n"; -import * as keydown_util from "./keydown_util"; -import * as popovers from "./popovers"; -import * as scroll_util from "./scroll_util"; -import * as settings_sections from "./settings_sections"; -import {redraw_active_users_list, redraw_deactivated_users_list} from "./settings_users"; +import * as blueslip from "./blueslip.ts"; +import * as browser_history from "./browser_history.ts"; +import * as components from "./components.ts"; +import {$t, $t_html} from "./i18n.ts"; +import * as keydown_util from "./keydown_util.ts"; +import * as popovers from "./popovers.ts"; +import * as scroll_util from "./scroll_util.ts"; +import * as settings_sections from "./settings_sections.js"; +import {redraw_active_users_list, redraw_deactivated_users_list} from "./settings_users.ts"; export let normal_settings; export let org_settings; diff --git a/web/src/settings_playgrounds.ts b/web/src/settings_playgrounds.ts index 4c0b697e31..bf3b336928 100644 --- a/web/src/settings_playgrounds.ts +++ b/web/src/settings_playgrounds.ts @@ -3,20 +3,20 @@ import $ from "jquery"; import render_confirm_delete_playground from "../templates/confirm_dialog/confirm_delete_playground.hbs"; import render_admin_playground_list from "../templates/settings/admin_playground_list.hbs"; -import {Typeahead} from "./bootstrap_typeahead"; -import * as bootstrap_typeahead from "./bootstrap_typeahead"; -import type {TypeaheadInputElement} from "./bootstrap_typeahead"; -import * as channel from "./channel"; -import * as confirm_dialog from "./confirm_dialog"; -import * as dialog_widget from "./dialog_widget"; -import {$t_html} from "./i18n"; -import * as ListWidget from "./list_widget"; -import * as realm_playground from "./realm_playground"; -import type {RealmPlayground} from "./realm_playground"; -import * as scroll_util from "./scroll_util"; -import {current_user, realm} from "./state_data"; -import {render_typeahead_item} from "./typeahead_helper"; -import * as ui_report from "./ui_report"; +import {Typeahead} from "./bootstrap_typeahead.ts"; +import * as bootstrap_typeahead from "./bootstrap_typeahead.ts"; +import type {TypeaheadInputElement} from "./bootstrap_typeahead.ts"; +import * as channel from "./channel.ts"; +import * as confirm_dialog from "./confirm_dialog.ts"; +import * as dialog_widget from "./dialog_widget.ts"; +import {$t_html} from "./i18n.ts"; +import * as ListWidget from "./list_widget.ts"; +import * as realm_playground from "./realm_playground.ts"; +import type {RealmPlayground} from "./realm_playground.ts"; +import * as scroll_util from "./scroll_util.ts"; +import {current_user, realm} from "./state_data.ts"; +import {render_typeahead_item} from "./typeahead_helper.ts"; +import * as ui_report from "./ui_report.ts"; let pygments_typeahead: Typeahead; diff --git a/web/src/settings_preferences.ts b/web/src/settings_preferences.ts index 1b7e1ab80c..b67856cefa 100644 --- a/web/src/settings_preferences.ts +++ b/web/src/settings_preferences.ts @@ -4,28 +4,28 @@ import assert from "minimalistic-assert"; import render_dialog_default_language from "../templates/default_language_modal.hbs"; -import * as channel from "./channel"; -import * as dialog_widget from "./dialog_widget"; -import * as emojisets from "./emojisets"; -import * as hash_parser from "./hash_parser"; -import {$t_html, get_language_list_columns, get_language_name} from "./i18n"; +import * as channel from "./channel.ts"; +import * as dialog_widget from "./dialog_widget.ts"; +import * as emojisets from "./emojisets.ts"; +import * as hash_parser from "./hash_parser.ts"; +import {$t_html, get_language_list_columns, get_language_name} from "./i18n.ts"; import { LEGACY_FONT_SIZE_PX, LEGACY_LINE_HEIGHT_PERCENT, NON_COMPACT_MODE_FONT_SIZE_PX, NON_COMPACT_MODE_LINE_HEIGHT_PERCENT, -} from "./information_density"; -import * as loading from "./loading"; -import * as overlays from "./overlays"; -import {page_params} from "./page_params"; -import type {RealmDefaultSettings} from "./realm_user_settings_defaults"; -import * as settings_components from "./settings_components"; -import type {RequestOpts} from "./settings_ui"; -import * as settings_ui from "./settings_ui"; -import {realm} from "./state_data"; -import * as ui_report from "./ui_report"; -import {user_settings} from "./user_settings"; -import type {UserSettings} from "./user_settings"; +} from "./information_density.ts"; +import * as loading from "./loading.ts"; +import * as overlays from "./overlays.ts"; +import {page_params} from "./page_params.ts"; +import type {RealmDefaultSettings} from "./realm_user_settings_defaults.ts"; +import * as settings_components from "./settings_components.ts"; +import type {RequestOpts} from "./settings_ui.ts"; +import * as settings_ui from "./settings_ui.ts"; +import {realm} from "./state_data.ts"; +import * as ui_report from "./ui_report.ts"; +import {user_settings} from "./user_settings.ts"; +import type {UserSettings} from "./user_settings.ts"; export type SettingsPanel = { container: string; diff --git a/web/src/settings_profile_fields.ts b/web/src/settings_profile_fields.ts index 93964679a9..9ec24f5b7a 100644 --- a/web/src/settings_profile_fields.ts +++ b/web/src/settings_profile_fields.ts @@ -9,22 +9,22 @@ import render_admin_profile_field_list from "../templates/settings/admin_profile import render_edit_custom_profile_field_form from "../templates/settings/edit_custom_profile_field_form.hbs"; import render_settings_profile_field_choice from "../templates/settings/profile_field_choice.hbs"; -import * as channel from "./channel"; -import * as confirm_dialog from "./confirm_dialog"; -import * as dialog_widget from "./dialog_widget"; -import {$t, $t_html} from "./i18n"; -import * as ListWidget from "./list_widget"; -import * as loading from "./loading"; -import * as people from "./people"; -import * as settings_components from "./settings_components"; -import type {FieldData, SelectFieldData} from "./settings_components"; -import * as settings_ui from "./settings_ui"; -import type {CustomProfileField} from "./state_data"; -import {current_user, realm} from "./state_data"; -import type {HTMLSelectOneElement} from "./types"; -import * as ui_report from "./ui_report"; -import {place_caret_at_end} from "./ui_util"; -import * as util from "./util"; +import * as channel from "./channel.ts"; +import * as confirm_dialog from "./confirm_dialog.ts"; +import * as dialog_widget from "./dialog_widget.ts"; +import {$t, $t_html} from "./i18n.ts"; +import * as ListWidget from "./list_widget.ts"; +import * as loading from "./loading.ts"; +import * as people from "./people.ts"; +import * as settings_components from "./settings_components.ts"; +import type {FieldData, SelectFieldData} from "./settings_components.ts"; +import * as settings_ui from "./settings_ui.ts"; +import type {CustomProfileField} from "./state_data.ts"; +import {current_user, realm} from "./state_data.ts"; +import type {HTMLSelectOneElement} from "./types.ts"; +import * as ui_report from "./ui_report.ts"; +import {place_caret_at_end} from "./ui_util.ts"; +import * as util from "./util.ts"; type FieldChoice = { value: string; diff --git a/web/src/settings_realm_domains.ts b/web/src/settings_realm_domains.ts index 76abca5a09..968d99280b 100644 --- a/web/src/settings_realm_domains.ts +++ b/web/src/settings_realm_domains.ts @@ -3,12 +3,12 @@ import $ from "jquery"; import render_settings_admin_realm_domains_list from "../templates/settings/admin_realm_domains_list.hbs"; import render_realm_domains_modal from "../templates/settings/realm_domains_modal.hbs"; -import * as channel from "./channel"; -import * as dialog_widget from "./dialog_widget"; -import {$t_html} from "./i18n"; -import {realm} from "./state_data"; -import * as ui_report from "./ui_report"; -import * as util from "./util"; +import * as channel from "./channel.ts"; +import * as dialog_widget from "./dialog_widget.ts"; +import {$t_html} from "./i18n.ts"; +import {realm} from "./state_data.ts"; +import * as ui_report from "./ui_report.ts"; +import * as util from "./util.ts"; type RealmDomain = { domain: string; diff --git a/web/src/settings_realm_user_settings_defaults.ts b/web/src/settings_realm_user_settings_defaults.ts index b81a9d6e37..073a3fa3c2 100644 --- a/web/src/settings_realm_user_settings_defaults.ts +++ b/web/src/settings_realm_user_settings_defaults.ts @@ -1,21 +1,21 @@ import $ from "jquery"; import assert from "minimalistic-assert"; -import * as audible_notifications from "./audible_notifications"; +import * as audible_notifications from "./audible_notifications.ts"; import { NON_COMPACT_MODE_FONT_SIZE_PX, NON_COMPACT_MODE_LINE_HEIGHT_PERCENT, -} from "./information_density"; -import * as overlays from "./overlays"; -import {page_params} from "./page_params"; -import {realm_user_settings_defaults} from "./realm_user_settings_defaults"; -import * as settings_notifications from "./settings_notifications"; -import * as settings_org from "./settings_org"; -import * as settings_preferences from "./settings_preferences"; -import type {SettingsPanel} from "./settings_preferences"; -import {current_user} from "./state_data"; -import type {HTMLSelectOneElement} from "./types"; -import * as util from "./util"; +} from "./information_density.ts"; +import * as overlays from "./overlays.ts"; +import {page_params} from "./page_params.ts"; +import {realm_user_settings_defaults} from "./realm_user_settings_defaults.ts"; +import * as settings_notifications from "./settings_notifications.ts"; +import * as settings_org from "./settings_org.ts"; +import * as settings_preferences from "./settings_preferences.ts"; +import type {SettingsPanel} from "./settings_preferences.ts"; +import {current_user} from "./state_data.ts"; +import type {HTMLSelectOneElement} from "./types.ts"; +import * as util from "./util.ts"; export let realm_default_settings_panel: SettingsPanel | undefined; diff --git a/web/src/settings_sections.js b/web/src/settings_sections.js index f847269964..517946998a 100644 --- a/web/src/settings_sections.js +++ b/web/src/settings_sections.js @@ -1,22 +1,22 @@ -import * as alert_words_ui from "./alert_words_ui"; -import * as attachments_ui from "./attachments_ui"; -import * as blueslip from "./blueslip"; -import * as settings_account from "./settings_account"; -import * as settings_bots from "./settings_bots"; -import * as settings_emoji from "./settings_emoji"; -import * as settings_exports from "./settings_exports"; -import * as settings_invites from "./settings_invites"; -import * as settings_linkifiers from "./settings_linkifiers"; -import * as settings_muted_users from "./settings_muted_users"; -import * as settings_notifications from "./settings_notifications"; -import * as settings_org from "./settings_org"; -import * as settings_playgrounds from "./settings_playgrounds"; -import * as settings_preferences from "./settings_preferences"; -import * as settings_profile_fields from "./settings_profile_fields"; -import * as settings_realm_user_settings_defaults from "./settings_realm_user_settings_defaults"; -import * as settings_streams from "./settings_streams"; -import * as settings_user_topics from "./settings_user_topics"; -import * as settings_users from "./settings_users"; +import * as alert_words_ui from "./alert_words_ui.ts"; +import * as attachments_ui from "./attachments_ui.ts"; +import * as blueslip from "./blueslip.ts"; +import * as settings_account from "./settings_account.ts"; +import * as settings_bots from "./settings_bots.ts"; +import * as settings_emoji from "./settings_emoji.ts"; +import * as settings_exports from "./settings_exports.ts"; +import * as settings_invites from "./settings_invites.ts"; +import * as settings_linkifiers from "./settings_linkifiers.ts"; +import * as settings_muted_users from "./settings_muted_users.ts"; +import * as settings_notifications from "./settings_notifications.ts"; +import * as settings_org from "./settings_org.ts"; +import * as settings_playgrounds from "./settings_playgrounds.ts"; +import * as settings_preferences from "./settings_preferences.ts"; +import * as settings_profile_fields from "./settings_profile_fields.ts"; +import * as settings_realm_user_settings_defaults from "./settings_realm_user_settings_defaults.ts"; +import * as settings_streams from "./settings_streams.ts"; +import * as settings_user_topics from "./settings_user_topics.ts"; +import * as settings_users from "./settings_users.ts"; const load_func_dict = new Map(); // group -> function const loaded_groups = new Set(); diff --git a/web/src/settings_streams.ts b/web/src/settings_streams.ts index 0bda06b404..6b275a0445 100644 --- a/web/src/settings_streams.ts +++ b/web/src/settings_streams.ts @@ -5,19 +5,19 @@ import render_add_default_streams from "../templates/settings/add_default_stream import render_admin_default_streams_list from "../templates/settings/admin_default_streams_list.hbs"; import render_default_stream_choice from "../templates/settings/default_stream_choice.hbs"; -import * as channel from "./channel"; -import * as dialog_widget from "./dialog_widget"; -import * as dropdown_widget from "./dropdown_widget"; -import * as hash_parser from "./hash_parser"; -import {$t_html} from "./i18n"; -import * as ListWidget from "./list_widget"; -import * as loading from "./loading"; -import * as scroll_util from "./scroll_util"; -import * as settings_profile_fields from "./settings_profile_fields"; -import {current_user} from "./state_data"; -import * as stream_data from "./stream_data"; -import * as sub_store from "./sub_store"; -import * as ui_report from "./ui_report"; +import * as channel from "./channel.ts"; +import * as dialog_widget from "./dialog_widget.ts"; +import * as dropdown_widget from "./dropdown_widget.ts"; +import * as hash_parser from "./hash_parser.ts"; +import {$t_html} from "./i18n.ts"; +import * as ListWidget from "./list_widget.ts"; +import * as loading from "./loading.ts"; +import * as scroll_util from "./scroll_util.ts"; +import * as settings_profile_fields from "./settings_profile_fields.ts"; +import {current_user} from "./state_data.ts"; +import * as stream_data from "./stream_data.ts"; +import * as sub_store from "./sub_store.ts"; +import * as ui_report from "./ui_report.ts"; function add_choice_row($widget: JQuery): void { if ($widget.closest(".choice-row").next().hasClass("choice-row")) { diff --git a/web/src/settings_toggle.js b/web/src/settings_toggle.js index 70feea0152..15f4738dbc 100644 --- a/web/src/settings_toggle.js +++ b/web/src/settings_toggle.js @@ -1,8 +1,8 @@ import $ from "jquery"; -import * as components from "./components"; -import {$t} from "./i18n"; -import * as settings_panel_menu from "./settings_panel_menu"; +import * as components from "./components.ts"; +import {$t} from "./i18n.ts"; +import * as settings_panel_menu from "./settings_panel_menu.js"; let toggler; diff --git a/web/src/settings_ui.ts b/web/src/settings_ui.ts index caa27e2262..dc6a417fef 100644 --- a/web/src/settings_ui.ts +++ b/web/src/settings_ui.ts @@ -2,10 +2,10 @@ import $ from "jquery"; import checkbox_image from "../images/checkbox-green.svg"; -import type {AjaxRequestHandler} from "./channel"; -import {$t, $t_html} from "./i18n"; -import * as loading from "./loading"; -import * as ui_report from "./ui_report"; +import type {AjaxRequestHandler} from "./channel.ts"; +import {$t, $t_html} from "./i18n.ts"; +import * as loading from "./loading.ts"; +import * as ui_report from "./ui_report.ts"; export type RequestOpts = { success_msg_html?: string | undefined; diff --git a/web/src/settings_user_topics.ts b/web/src/settings_user_topics.ts index ec289b41f0..118856bb55 100644 --- a/web/src/settings_user_topics.ts +++ b/web/src/settings_user_topics.ts @@ -3,11 +3,11 @@ import assert from "minimalistic-assert"; import render_user_topic_ui_row from "../templates/user_topic_ui_row.hbs"; -import * as ListWidget from "./list_widget"; -import * as scroll_util from "./scroll_util"; -import * as settings_config from "./settings_config"; -import * as user_topics from "./user_topics"; -import type {UserTopic} from "./user_topics"; +import * as ListWidget from "./list_widget.ts"; +import * as scroll_util from "./scroll_util.ts"; +import * as settings_config from "./settings_config.ts"; +import * as user_topics from "./user_topics.ts"; +import type {UserTopic} from "./user_topics.ts"; export let loaded = false; diff --git a/web/src/settings_users.ts b/web/src/settings_users.ts index 50276b2ed7..2513b94158 100644 --- a/web/src/settings_users.ts +++ b/web/src/settings_users.ts @@ -4,29 +4,29 @@ import type * as tippy from "tippy.js"; import render_admin_user_list from "../templates/settings/admin_user_list.hbs"; -import * as blueslip from "./blueslip"; -import * as browser_history from "./browser_history"; -import * as channel from "./channel"; -import * as dialog_widget from "./dialog_widget"; -import * as dropdown_widget from "./dropdown_widget"; -import {$t} from "./i18n"; -import type {ListWidget as ListWidgetType} from "./list_widget"; -import * as ListWidget from "./list_widget"; -import * as loading from "./loading"; -import * as people from "./people"; -import type {User} from "./people"; -import * as presence from "./presence"; -import * as scroll_util from "./scroll_util"; -import * as settings_bots from "./settings_bots"; -import * as settings_config from "./settings_config"; -import * as settings_data from "./settings_data"; -import * as setting_invites from "./settings_invites"; -import {current_user} from "./state_data"; -import * as timerender from "./timerender"; -import * as user_deactivation_ui from "./user_deactivation_ui"; -import * as user_profile from "./user_profile"; -import * as user_sort from "./user_sort"; -import * as util from "./util"; +import * as blueslip from "./blueslip.ts"; +import * as browser_history from "./browser_history.ts"; +import * as channel from "./channel.ts"; +import * as dialog_widget from "./dialog_widget.ts"; +import * as dropdown_widget from "./dropdown_widget.ts"; +import {$t} from "./i18n.ts"; +import type {ListWidget as ListWidgetType} from "./list_widget.ts"; +import * as ListWidget from "./list_widget.ts"; +import * as loading from "./loading.ts"; +import * as people from "./people.ts"; +import type {User} from "./people.ts"; +import * as presence from "./presence.ts"; +import * as scroll_util from "./scroll_util.ts"; +import * as settings_bots from "./settings_bots.ts"; +import * as settings_config from "./settings_config.ts"; +import * as settings_data from "./settings_data.ts"; +import * as setting_invites from "./settings_invites.ts"; +import {current_user} from "./state_data.ts"; +import * as timerender from "./timerender.ts"; +import * as user_deactivation_ui from "./user_deactivation_ui.ts"; +import * as user_profile from "./user_profile.ts"; +import * as user_sort from "./user_sort.ts"; +import * as util from "./util.ts"; export const active_user_list_dropdown_widget_name = "active_user_list_select_user_role"; export const deactivated_user_list_dropdown_widget_name = "deactivated_user_list_select_user_role"; diff --git a/web/src/setup.ts b/web/src/setup.ts index 9828504c09..c11aec1e9c 100644 --- a/web/src/setup.ts +++ b/web/src/setup.ts @@ -1,8 +1,8 @@ import $ from "jquery"; -import * as blueslip from "./blueslip"; -import * as loading from "./loading"; -import * as util from "./util"; +import * as blueslip from "./blueslip.ts"; +import * as loading from "./loading.ts"; +import * as util from "./util.ts"; export let page_load_time: number | undefined; diff --git a/web/src/sidebar_ui.ts b/web/src/sidebar_ui.ts index 4095dae166..23f5fa5ee2 100644 --- a/web/src/sidebar_ui.ts +++ b/web/src/sidebar_ui.ts @@ -4,22 +4,22 @@ import render_left_sidebar from "../templates/left_sidebar.hbs"; import render_buddy_list_popover from "../templates/popovers/buddy_list_popover.hbs"; import render_right_sidebar from "../templates/right_sidebar.hbs"; -import {buddy_list} from "./buddy_list"; -import {media_breakpoints_num} from "./css_variables"; -import {reorder_left_sidebar_navigation_list} from "./left_sidebar_navigation_area"; -import {localstorage} from "./localstorage"; -import * as message_lists from "./message_lists"; -import * as message_viewport from "./message_viewport"; -import {page_params} from "./page_params"; -import * as popover_menus from "./popover_menus"; -import * as rendered_markdown from "./rendered_markdown"; -import * as resize from "./resize"; -import * as settings_config from "./settings_config"; -import * as settings_data from "./settings_data"; -import * as spectators from "./spectators"; -import {current_user} from "./state_data"; -import * as ui_util from "./ui_util"; -import {user_settings} from "./user_settings"; +import {buddy_list} from "./buddy_list.ts"; +import {media_breakpoints_num} from "./css_variables.js"; +import {reorder_left_sidebar_navigation_list} from "./left_sidebar_navigation_area.ts"; +import {localstorage} from "./localstorage.ts"; +import * as message_lists from "./message_lists.ts"; +import * as message_viewport from "./message_viewport.ts"; +import {page_params} from "./page_params.ts"; +import * as popover_menus from "./popover_menus.ts"; +import * as rendered_markdown from "./rendered_markdown.ts"; +import * as resize from "./resize.ts"; +import * as settings_config from "./settings_config.ts"; +import * as settings_data from "./settings_data.ts"; +import * as spectators from "./spectators.ts"; +import {current_user} from "./state_data.ts"; +import * as ui_util from "./ui_util.ts"; +import {user_settings} from "./user_settings.ts"; function save_sidebar_toggle_status(): void { const ls = localstorage(); diff --git a/web/src/spectators.ts b/web/src/spectators.ts index 625dba9444..99af2d50f8 100644 --- a/web/src/spectators.ts +++ b/web/src/spectators.ts @@ -9,10 +9,10 @@ import $ from "jquery"; import render_login_to_access_modal from "../templates/login_to_access.hbs"; -import {page_params} from "./base_page_params"; -import * as browser_history from "./browser_history"; -import * as modals from "./modals"; -import {realm} from "./state_data"; +import {page_params} from "./base_page_params.ts"; +import * as browser_history from "./browser_history.ts"; +import * as modals from "./modals.ts"; +import {realm} from "./state_data.ts"; export function current_hash_as_next(): string { return `next=/${encodeURIComponent(window.location.hash)}`; diff --git a/web/src/spoilers.ts b/web/src/spoilers.ts index ff7c09b7e5..d7ed450c62 100644 --- a/web/src/spoilers.ts +++ b/web/src/spoilers.ts @@ -1,6 +1,6 @@ import $ from "jquery"; -import * as util from "./util"; +import * as util from "./util.ts"; function collapse_spoiler($spoiler: JQuery): void { const spoiler_height = $spoiler.height() ?? 0; diff --git a/web/src/starred_messages.ts b/web/src/starred_messages.ts index c302a3a918..fa00495559 100644 --- a/web/src/starred_messages.ts +++ b/web/src/starred_messages.ts @@ -1,5 +1,5 @@ -import * as message_store from "./message_store"; -import type {StateData} from "./state_data"; +import * as message_store from "./message_store.ts"; +import type {StateData} from "./state_data.ts"; export const starred_ids = new Set(); diff --git a/web/src/starred_messages_ui.ts b/web/src/starred_messages_ui.ts index 7b287dc4cd..df9bbe7356 100644 --- a/web/src/starred_messages_ui.ts +++ b/web/src/starred_messages_ui.ts @@ -1,18 +1,18 @@ import render_confirm_unstar_all_messages from "../templates/confirm_dialog/confirm_unstar_all_messages.hbs"; import render_confirm_unstar_all_messages_in_topic from "../templates/confirm_dialog/confirm_unstar_all_messages_in_topic.hbs"; -import * as confirm_dialog from "./confirm_dialog"; -import {$t_html} from "./i18n"; -import * as left_sidebar_navigation_area from "./left_sidebar_navigation_area"; -import * as message_flags from "./message_flags"; -import * as message_live_update from "./message_live_update"; -import * as message_store from "./message_store"; -import type {Message} from "./message_store"; -import * as popover_menus from "./popover_menus"; -import * as starred_messages from "./starred_messages"; -import * as sub_store from "./sub_store"; -import * as unread_ops from "./unread_ops"; -import {user_settings} from "./user_settings"; +import * as confirm_dialog from "./confirm_dialog.ts"; +import {$t_html} from "./i18n.ts"; +import * as left_sidebar_navigation_area from "./left_sidebar_navigation_area.ts"; +import * as message_flags from "./message_flags.ts"; +import * as message_live_update from "./message_live_update.ts"; +import * as message_store from "./message_store.ts"; +import type {Message} from "./message_store.ts"; +import * as popover_menus from "./popover_menus.ts"; +import * as starred_messages from "./starred_messages.ts"; +import * as sub_store from "./sub_store.ts"; +import * as unread_ops from "./unread_ops.ts"; +import {user_settings} from "./user_settings.ts"; export function toggle_starred_and_update_server(message: Message): void { if (message.locally_echoed) { diff --git a/web/src/state_data.ts b/web/src/state_data.ts index 8e70f9f7d7..a828725c1c 100644 --- a/web/src/state_data.ts +++ b/web/src/state_data.ts @@ -1,14 +1,14 @@ import {z} from "zod"; -import {server_add_bot_schema} from "./bot_types"; -import {realm_default_settings_schema} from "./realm_user_settings_defaults"; +import {server_add_bot_schema} from "./bot_types.ts"; +import {realm_default_settings_schema} from "./realm_user_settings_defaults.ts"; import { api_stream_subscription_schema, never_subscribed_stream_schema, stream_schema, -} from "./stream_types"; -import {user_settings_schema} from "./user_settings"; -import {user_status_schema} from "./user_status_types"; +} from "./stream_types.ts"; +import {user_settings_schema} from "./user_settings.ts"; +import {user_status_schema} from "./user_status_types.ts"; const NOT_TYPED_YET = z.unknown(); diff --git a/web/src/stats/page_params.ts b/web/src/stats/page_params.ts index 389a1f1f5c..f0da9564e4 100644 --- a/web/src/stats/page_params.ts +++ b/web/src/stats/page_params.ts @@ -1,6 +1,6 @@ import assert from "minimalistic-assert"; -import {page_params as base_page_params} from "../base_page_params"; +import {page_params as base_page_params} from "../base_page_params.ts"; assert(base_page_params.page_type === "stats"); diff --git a/web/src/stats/stats.ts b/web/src/stats/stats.ts index 10b3e1a397..466b41e31f 100644 --- a/web/src/stats/stats.ts +++ b/web/src/stats/stats.ts @@ -6,10 +6,10 @@ import PlotlyPie from "plotly.js/lib/pie"; import * as tippy from "tippy.js"; import {z} from "zod"; -import * as blueslip from "../blueslip"; -import {$t, $t_html} from "../i18n"; +import * as blueslip from "../blueslip.ts"; +import {$t, $t_html} from "../i18n.ts"; -import {page_params} from "./page_params"; +import {page_params} from "./page_params.ts"; Plotly.register([PlotlyBar, PlotlyPie]); diff --git a/web/src/stream_card_popover.ts b/web/src/stream_card_popover.ts index df5e278653..b754304b4a 100644 --- a/web/src/stream_card_popover.ts +++ b/web/src/stream_card_popover.ts @@ -3,13 +3,13 @@ import assert from "minimalistic-assert"; import render_stream_card_popover from "../templates/popovers/stream_card_popover.hbs"; -import * as browser_history from "./browser_history"; -import * as hash_util from "./hash_util"; -import * as modals from "./modals"; -import * as popover_menus from "./popover_menus"; -import * as stream_data from "./stream_data"; -import * as sub_store from "./sub_store"; -import * as ui_util from "./ui_util"; +import * as browser_history from "./browser_history.ts"; +import * as hash_util from "./hash_util.ts"; +import * as modals from "./modals.ts"; +import * as popover_menus from "./popover_menus.ts"; +import * as stream_data from "./stream_data.ts"; +import * as sub_store from "./sub_store.ts"; +import * as ui_util from "./ui_util.ts"; let stream_id: number | undefined; diff --git a/web/src/stream_color.ts b/web/src/stream_color.ts index 027923a9e5..f66b9a01b2 100644 --- a/web/src/stream_color.ts +++ b/web/src/stream_color.ts @@ -5,10 +5,10 @@ import mixPlugin from "colord/plugins/mix"; import $ from "jquery"; import type tinycolor from "tinycolor2"; -import {$t} from "./i18n"; -import * as settings_data from "./settings_data"; -import * as stream_data from "./stream_data"; -import * as stream_settings_api from "./stream_settings_api"; +import {$t} from "./i18n.ts"; +import * as settings_data from "./settings_data.ts"; +import * as stream_data from "./stream_data.ts"; +import * as stream_settings_api from "./stream_settings_api.ts"; extend([lchPlugin, mixPlugin]); diff --git a/web/src/stream_color_events.ts b/web/src/stream_color_events.ts index ed569c7b8d..81fe181c9d 100644 --- a/web/src/stream_color_events.ts +++ b/web/src/stream_color_events.ts @@ -1,12 +1,12 @@ import $ from "jquery"; -import * as inbox_util from "./inbox_util"; -import * as message_lists from "./message_lists"; -import * as message_view_header from "./message_view_header"; -import * as overlays from "./overlays"; -import * as stream_color from "./stream_color"; -import * as stream_data from "./stream_data"; -import type {StreamSubscription} from "./sub_store"; +import * as inbox_util from "./inbox_util.ts"; +import * as message_lists from "./message_lists.ts"; +import * as message_view_header from "./message_view_header.ts"; +import * as overlays from "./overlays.ts"; +import * as stream_color from "./stream_color.ts"; +import * as stream_data from "./stream_data.ts"; +import type {StreamSubscription} from "./sub_store.ts"; function update_table_message_recipient_stream_color( table: JQuery, diff --git a/web/src/stream_create.ts b/web/src/stream_create.ts index 89a26bd3fb..e951014e88 100644 --- a/web/src/stream_create.ts +++ b/web/src/stream_create.ts @@ -5,24 +5,24 @@ import {z} from "zod"; import render_subscription_invites_warning_modal from "../templates/confirm_dialog/confirm_subscription_invites_warning.hbs"; import render_change_stream_info_modal from "../templates/stream_settings/change_stream_info_modal.hbs"; -import * as channel from "./channel"; -import * as confirm_dialog from "./confirm_dialog"; -import * as dialog_widget from "./dialog_widget"; -import {$t, $t_html} from "./i18n"; -import * as keydown_util from "./keydown_util"; -import * as loading from "./loading"; -import * as onboarding_steps from "./onboarding_steps"; -import * as people from "./people"; -import * as settings_data from "./settings_data"; -import {current_user, realm} from "./state_data"; -import * as stream_create_subscribers from "./stream_create_subscribers"; -import * as stream_data from "./stream_data"; -import * as stream_settings_components from "./stream_settings_components"; -import * as stream_settings_data from "./stream_settings_data"; -import * as stream_ui_updates from "./stream_ui_updates"; -import type {HTMLSelectOneElement} from "./types"; -import * as ui_report from "./ui_report"; -import * as util from "./util"; +import * as channel from "./channel.ts"; +import * as confirm_dialog from "./confirm_dialog.ts"; +import * as dialog_widget from "./dialog_widget.ts"; +import {$t, $t_html} from "./i18n.ts"; +import * as keydown_util from "./keydown_util.ts"; +import * as loading from "./loading.ts"; +import * as onboarding_steps from "./onboarding_steps.ts"; +import * as people from "./people.ts"; +import * as settings_data from "./settings_data.ts"; +import {current_user, realm} from "./state_data.ts"; +import * as stream_create_subscribers from "./stream_create_subscribers.ts"; +import * as stream_data from "./stream_data.ts"; +import * as stream_settings_components from "./stream_settings_components.ts"; +import * as stream_settings_data from "./stream_settings_data.ts"; +import * as stream_ui_updates from "./stream_ui_updates.ts"; +import type {HTMLSelectOneElement} from "./types.ts"; +import * as ui_report from "./ui_report.ts"; +import * as util from "./util.ts"; let created_stream: string | undefined; // Default is true since the current user is added to diff --git a/web/src/stream_create_subscribers.ts b/web/src/stream_create_subscribers.ts index 7ed1f76e65..580d1eddbd 100644 --- a/web/src/stream_create_subscribers.ts +++ b/web/src/stream_create_subscribers.ts @@ -3,14 +3,14 @@ import $ from "jquery"; import render_new_stream_user from "../templates/stream_settings/new_stream_user.hbs"; import render_new_stream_users from "../templates/stream_settings/new_stream_users.hbs"; -import * as add_subscribers_pill from "./add_subscribers_pill"; -import * as ListWidget from "./list_widget"; -import type {ListWidget as ListWidgetType} from "./list_widget"; -import * as people from "./people"; -import {current_user} from "./state_data"; -import * as stream_create_subscribers_data from "./stream_create_subscribers_data"; -import type {CombinedPillContainer} from "./typeahead_helper"; -import * as user_sort from "./user_sort"; +import * as add_subscribers_pill from "./add_subscribers_pill.ts"; +import * as ListWidget from "./list_widget.ts"; +import type {ListWidget as ListWidgetType} from "./list_widget.ts"; +import * as people from "./people.ts"; +import {current_user} from "./state_data.ts"; +import * as stream_create_subscribers_data from "./stream_create_subscribers_data.ts"; +import type {CombinedPillContainer} from "./typeahead_helper.ts"; +import * as user_sort from "./user_sort.ts"; let pill_widget: CombinedPillContainer; let all_users_list_widget: ListWidgetType; diff --git a/web/src/stream_create_subscribers_data.ts b/web/src/stream_create_subscribers_data.ts index be9a165ee0..b0d701140f 100644 --- a/web/src/stream_create_subscribers_data.ts +++ b/web/src/stream_create_subscribers_data.ts @@ -1,8 +1,8 @@ import _ from "lodash"; -import * as people from "./people"; -import type {User} from "./people"; -import {current_user} from "./state_data"; +import * as people from "./people.ts"; +import type {User} from "./people.ts"; +import {current_user} from "./state_data.ts"; let user_id_set: Set; let soft_remove_user_id_set: Set; diff --git a/web/src/stream_data.ts b/web/src/stream_data.ts index 3539276f8b..4112177a59 100644 --- a/web/src/stream_data.ts +++ b/web/src/stream_data.ts @@ -1,28 +1,28 @@ import assert from "minimalistic-assert"; -import * as blueslip from "./blueslip"; -import * as color_data from "./color_data"; -import {FoldDict} from "./fold_dict"; -import {page_params} from "./page_params"; -import * as peer_data from "./peer_data"; -import type {User} from "./people"; -import * as people from "./people"; -import * as settings_config from "./settings_config"; -import * as settings_data from "./settings_data"; -import type {StateData} from "./state_data"; -import {current_user, realm} from "./state_data"; -import type {StreamPostPolicy} from "./stream_types"; -import * as sub_store from "./sub_store"; +import * as blueslip from "./blueslip.ts"; +import * as color_data from "./color_data.ts"; +import {FoldDict} from "./fold_dict.ts"; +import {page_params} from "./page_params.ts"; +import * as peer_data from "./peer_data.ts"; +import type {User} from "./people.ts"; +import * as people from "./people.ts"; +import * as settings_config from "./settings_config.ts"; +import * as settings_data from "./settings_data.ts"; +import type {StateData} from "./state_data.ts"; +import {current_user, realm} from "./state_data.ts"; +import type {StreamPostPolicy} from "./stream_types.ts"; +import * as sub_store from "./sub_store.ts"; import type { ApiStreamSubscription, NeverSubscribedStream, Stream, StreamSpecificNotificationSettings, StreamSubscription, -} from "./sub_store"; -import * as user_groups from "./user_groups"; -import {user_settings} from "./user_settings"; -import * as util from "./util"; +} from "./sub_store.ts"; +import * as user_groups from "./user_groups.ts"; +import {user_settings} from "./user_settings.ts"; +import * as util from "./util.ts"; // Type for the parameter of `create_sub_from_server_data` function. type ApiGenericStreamSubscription = NeverSubscribedStream | ApiStreamSubscription; diff --git a/web/src/stream_edit.ts b/web/src/stream_edit.ts index 50a441e60c..a97a2f68fb 100644 --- a/web/src/stream_edit.ts +++ b/web/src/stream_edit.ts @@ -11,44 +11,44 @@ import render_copy_email_address_modal from "../templates/stream_settings/copy_e import render_stream_description from "../templates/stream_settings/stream_description.hbs"; import render_stream_settings from "../templates/stream_settings/stream_settings.hbs"; -import * as blueslip from "./blueslip"; -import * as browser_history from "./browser_history"; -import * as channel from "./channel"; -import * as confirm_dialog from "./confirm_dialog"; -import {show_copied_confirmation} from "./copied_tooltip"; -import * as dialog_widget from "./dialog_widget"; -import * as dropdown_widget from "./dropdown_widget"; -import {$t, $t_html} from "./i18n"; -import * as keydown_util from "./keydown_util"; -import * as narrow_state from "./narrow_state"; -import * as popovers from "./popovers"; -import {postprocess_content} from "./postprocess_content"; -import * as scroll_util from "./scroll_util"; -import * as settings_components from "./settings_components"; -import * as settings_config from "./settings_config"; -import * as settings_org from "./settings_org"; -import {current_user, realm} from "./state_data"; -import * as stream_color from "./stream_color"; -import * as stream_data from "./stream_data"; -import * as stream_edit_subscribers from "./stream_edit_subscribers"; -import * as stream_edit_toggler from "./stream_edit_toggler"; -import * as stream_settings_api from "./stream_settings_api"; -import type {SubData} from "./stream_settings_api"; -import * as stream_settings_components from "./stream_settings_components"; -import * as stream_settings_containers from "./stream_settings_containers"; -import * as stream_settings_data from "./stream_settings_data"; -import type {SettingsSubscription} from "./stream_settings_data"; +import * as blueslip from "./blueslip.ts"; +import * as browser_history from "./browser_history.ts"; +import * as channel from "./channel.ts"; +import * as confirm_dialog from "./confirm_dialog.ts"; +import {show_copied_confirmation} from "./copied_tooltip.ts"; +import * as dialog_widget from "./dialog_widget.ts"; +import * as dropdown_widget from "./dropdown_widget.ts"; +import {$t, $t_html} from "./i18n.ts"; +import * as keydown_util from "./keydown_util.ts"; +import * as narrow_state from "./narrow_state.ts"; +import * as popovers from "./popovers.ts"; +import {postprocess_content} from "./postprocess_content.ts"; +import * as scroll_util from "./scroll_util.ts"; +import * as settings_components from "./settings_components.ts"; +import * as settings_config from "./settings_config.ts"; +import * as settings_org from "./settings_org.ts"; +import {current_user, realm} from "./state_data.ts"; +import * as stream_color from "./stream_color.ts"; +import * as stream_data from "./stream_data.ts"; +import * as stream_edit_subscribers from "./stream_edit_subscribers.ts"; +import * as stream_edit_toggler from "./stream_edit_toggler.ts"; +import * as stream_settings_api from "./stream_settings_api.ts"; +import type {SubData} from "./stream_settings_api.ts"; +import * as stream_settings_components from "./stream_settings_components.ts"; +import * as stream_settings_containers from "./stream_settings_containers.ts"; +import * as stream_settings_data from "./stream_settings_data.ts"; +import type {SettingsSubscription} from "./stream_settings_data.ts"; import { stream_properties_schema, stream_specific_notification_settings_schema, -} from "./stream_types"; -import * as stream_ui_updates from "./stream_ui_updates"; -import * as sub_store from "./sub_store"; -import type {StreamSubscription} from "./sub_store"; -import * as ui_report from "./ui_report"; -import * as user_groups from "./user_groups"; -import {user_settings} from "./user_settings"; -import * as util from "./util"; +} from "./stream_types.ts"; +import * as stream_ui_updates from "./stream_ui_updates.ts"; +import * as sub_store from "./sub_store.ts"; +import type {StreamSubscription} from "./sub_store.ts"; +import * as ui_report from "./ui_report.ts"; +import * as user_groups from "./user_groups.ts"; +import {user_settings} from "./user_settings.ts"; +import * as util from "./util.ts"; type StreamSetting = { name: z.output; diff --git a/web/src/stream_edit_subscribers.ts b/web/src/stream_edit_subscribers.ts index cba3fd1a5a..4c2f2b19f1 100644 --- a/web/src/stream_edit_subscribers.ts +++ b/web/src/stream_edit_subscribers.ts @@ -8,26 +8,26 @@ import render_stream_member_list_entry from "../templates/stream_settings/stream import render_stream_members_table from "../templates/stream_settings/stream_members_table.hbs"; import render_stream_subscription_request_result from "../templates/stream_settings/stream_subscription_request_result.hbs"; -import * as add_subscribers_pill from "./add_subscribers_pill"; -import * as blueslip from "./blueslip"; -import * as confirm_dialog from "./confirm_dialog"; -import * as hash_parser from "./hash_parser"; -import {$t, $t_html} from "./i18n"; -import * as ListWidget from "./list_widget"; -import type {ListWidget as ListWidgetType} from "./list_widget"; -import * as peer_data from "./peer_data"; -import * as people from "./people"; -import type {User} from "./people"; -import * as scroll_util from "./scroll_util"; -import {current_user} from "./state_data"; -import * as stream_data from "./stream_data"; -import * as stream_settings_containers from "./stream_settings_containers"; -import type {SettingsSubscription} from "./stream_settings_data"; -import * as sub_store from "./sub_store"; -import type {StreamSubscription} from "./sub_store"; -import * as subscriber_api from "./subscriber_api"; -import type {CombinedPillContainer} from "./typeahead_helper"; -import * as user_sort from "./user_sort"; +import * as add_subscribers_pill from "./add_subscribers_pill.ts"; +import * as blueslip from "./blueslip.ts"; +import * as confirm_dialog from "./confirm_dialog.ts"; +import * as hash_parser from "./hash_parser.ts"; +import {$t, $t_html} from "./i18n.ts"; +import * as ListWidget from "./list_widget.ts"; +import type {ListWidget as ListWidgetType} from "./list_widget.ts"; +import * as peer_data from "./peer_data.ts"; +import * as people from "./people.ts"; +import type {User} from "./people.ts"; +import * as scroll_util from "./scroll_util.ts"; +import {current_user} from "./state_data.ts"; +import * as stream_data from "./stream_data.ts"; +import * as stream_settings_containers from "./stream_settings_containers.ts"; +import type {SettingsSubscription} from "./stream_settings_data.ts"; +import * as sub_store from "./sub_store.ts"; +import type {StreamSubscription} from "./sub_store.ts"; +import * as subscriber_api from "./subscriber_api.ts"; +import type {CombinedPillContainer} from "./typeahead_helper.ts"; +import * as user_sort from "./user_sort.ts"; const remove_user_id_api_response_schema = z.object({ removed: z.array(z.string()), diff --git a/web/src/stream_edit_toggler.ts b/web/src/stream_edit_toggler.ts index c5b5ff8c4f..e38e7c46fd 100644 --- a/web/src/stream_edit_toggler.ts +++ b/web/src/stream_edit_toggler.ts @@ -1,10 +1,10 @@ import $ from "jquery"; -import * as browser_history from "./browser_history"; -import * as components from "./components"; -import * as hash_util from "./hash_util"; -import {$t} from "./i18n"; -import * as sub_store from "./sub_store"; +import * as browser_history from "./browser_history.ts"; +import * as components from "./components.ts"; +import * as hash_util from "./hash_util.ts"; +import {$t} from "./i18n.ts"; +import * as sub_store from "./sub_store.ts"; export let toggler: components.Toggle; export let select_tab = "personal"; diff --git a/web/src/stream_events.js b/web/src/stream_events.js index 43c10fa98d..cff1be0a36 100644 --- a/web/src/stream_events.js +++ b/web/src/stream_events.js @@ -4,32 +4,32 @@ import assert from "minimalistic-assert"; import render_inline_decorated_stream_name from "../templates/inline_decorated_stream_name.hbs"; import render_first_stream_created_modal from "../templates/stream_settings/first_stream_created_modal.hbs"; -import * as activity_ui from "./activity_ui"; -import * as blueslip from "./blueslip"; -import * as browser_history from "./browser_history"; -import * as color_data from "./color_data"; -import * as compose_recipient from "./compose_recipient"; -import * as dialog_widget from "./dialog_widget"; -import * as hash_util from "./hash_util"; -import {$t, $t_html} from "./i18n"; -import * as message_lists from "./message_lists"; -import * as message_view_header from "./message_view_header"; -import * as narrow_state from "./narrow_state"; -import * as overlays from "./overlays"; -import * as peer_data from "./peer_data"; -import * as people from "./people"; -import * as recent_view_ui from "./recent_view_ui"; -import * as settings_notifications from "./settings_notifications"; -import * as stream_color_events from "./stream_color_events"; -import * as stream_create from "./stream_create"; -import * as stream_data from "./stream_data"; -import * as stream_list from "./stream_list"; -import * as stream_muting from "./stream_muting"; -import * as stream_settings_api from "./stream_settings_api"; -import * as stream_settings_ui from "./stream_settings_ui"; -import * as sub_store from "./sub_store"; -import * as unread_ui from "./unread_ui"; -import * as user_profile from "./user_profile"; +import * as activity_ui from "./activity_ui.ts"; +import * as blueslip from "./blueslip.ts"; +import * as browser_history from "./browser_history.ts"; +import * as color_data from "./color_data.ts"; +import * as compose_recipient from "./compose_recipient.ts"; +import * as dialog_widget from "./dialog_widget.ts"; +import * as hash_util from "./hash_util.ts"; +import {$t, $t_html} from "./i18n.ts"; +import * as message_lists from "./message_lists.ts"; +import * as message_view_header from "./message_view_header.ts"; +import * as narrow_state from "./narrow_state.ts"; +import * as overlays from "./overlays.ts"; +import * as peer_data from "./peer_data.ts"; +import * as people from "./people.ts"; +import * as recent_view_ui from "./recent_view_ui.ts"; +import * as settings_notifications from "./settings_notifications.ts"; +import * as stream_color_events from "./stream_color_events.ts"; +import * as stream_create from "./stream_create.ts"; +import * as stream_data from "./stream_data.ts"; +import * as stream_list from "./stream_list.ts"; +import * as stream_muting from "./stream_muting.js"; +import * as stream_settings_api from "./stream_settings_api.ts"; +import * as stream_settings_ui from "./stream_settings_ui.js"; +import * as sub_store from "./sub_store.ts"; +import * as unread_ui from "./unread_ui.ts"; +import * as user_profile from "./user_profile.ts"; // In theory, this function should apply the account-level defaults, // however, they are only called after a manual override, so diff --git a/web/src/stream_list.ts b/web/src/stream_list.ts index f1e19af4e9..be8176be9f 100644 --- a/web/src/stream_list.ts +++ b/web/src/stream_list.ts @@ -10,34 +10,34 @@ import render_stream_sidebar_row from "../templates/stream_sidebar_row.hbs"; import render_stream_subheader from "../templates/streams_subheader.hbs"; import render_subscribe_to_more_streams from "../templates/subscribe_to_more_streams.hbs"; -import * as blueslip from "./blueslip"; -import * as browser_history from "./browser_history"; -import type {Filter} from "./filter"; -import * as hash_util from "./hash_util"; -import {$t} from "./i18n"; -import * as keydown_util from "./keydown_util"; -import {ListCursor} from "./list_cursor"; -import * as narrow_state from "./narrow_state"; -import * as pm_list from "./pm_list"; -import * as popovers from "./popovers"; -import * as resize from "./resize"; -import * as scroll_util from "./scroll_util"; -import {web_channel_default_view_values} from "./settings_config"; -import * as settings_data from "./settings_data"; -import * as sidebar_ui from "./sidebar_ui"; -import * as stream_data from "./stream_data"; -import * as stream_list_sort from "./stream_list_sort"; -import * as stream_topic_history from "./stream_topic_history"; -import * as stream_topic_history_util from "./stream_topic_history_util"; -import * as sub_store from "./sub_store"; -import type {StreamSubscription} from "./sub_store"; -import {LONG_HOVER_DELAY} from "./tippyjs"; -import * as topic_list from "./topic_list"; -import * as topic_list_data from "./topic_list_data"; -import * as ui_util from "./ui_util"; -import * as unread from "./unread"; -import type {FullUnreadCountsData, StreamCountInfo} from "./unread"; -import {user_settings} from "./user_settings"; +import * as blueslip from "./blueslip.ts"; +import * as browser_history from "./browser_history.ts"; +import type {Filter} from "./filter.ts"; +import * as hash_util from "./hash_util.ts"; +import {$t} from "./i18n.ts"; +import * as keydown_util from "./keydown_util.ts"; +import {ListCursor} from "./list_cursor.ts"; +import * as narrow_state from "./narrow_state.ts"; +import * as pm_list from "./pm_list.ts"; +import * as popovers from "./popovers.ts"; +import * as resize from "./resize.ts"; +import * as scroll_util from "./scroll_util.ts"; +import {web_channel_default_view_values} from "./settings_config.ts"; +import * as settings_data from "./settings_data.ts"; +import * as sidebar_ui from "./sidebar_ui.ts"; +import * as stream_data from "./stream_data.ts"; +import * as stream_list_sort from "./stream_list_sort.ts"; +import * as stream_topic_history from "./stream_topic_history.ts"; +import * as stream_topic_history_util from "./stream_topic_history_util.ts"; +import * as sub_store from "./sub_store.ts"; +import type {StreamSubscription} from "./sub_store.ts"; +import {LONG_HOVER_DELAY} from "./tippyjs.ts"; +import * as topic_list from "./topic_list.ts"; +import * as topic_list_data from "./topic_list_data.ts"; +import * as ui_util from "./ui_util.ts"; +import * as unread from "./unread.ts"; +import type {FullUnreadCountsData, StreamCountInfo} from "./unread.ts"; +import {user_settings} from "./user_settings.ts"; let pending_stream_list_rerender = false; let zoomed_in = false; diff --git a/web/src/stream_list_sort.ts b/web/src/stream_list_sort.ts index 36f9ed9618..22465d1c0a 100644 --- a/web/src/stream_list_sort.ts +++ b/web/src/stream_list_sort.ts @@ -1,12 +1,12 @@ import assert from "minimalistic-assert"; -import * as settings_config from "./settings_config"; -import * as stream_data from "./stream_data"; -import * as stream_topic_history from "./stream_topic_history"; -import * as sub_store from "./sub_store"; -import type {StreamSubscription} from "./sub_store"; -import {user_settings} from "./user_settings"; -import * as util from "./util"; +import * as settings_config from "./settings_config.ts"; +import * as stream_data from "./stream_data.ts"; +import * as stream_topic_history from "./stream_topic_history.ts"; +import * as sub_store from "./sub_store.ts"; +import type {StreamSubscription} from "./sub_store.ts"; +import {user_settings} from "./user_settings.ts"; +import * as util from "./util.ts"; let first_render_completed = false; let previous_pinned: number[] = []; diff --git a/web/src/stream_muting.js b/web/src/stream_muting.js index 8821e5e12c..de4ac80109 100644 --- a/web/src/stream_muting.js +++ b/web/src/stream_muting.js @@ -1,8 +1,8 @@ -import * as message_lists from "./message_lists"; -import * as settings_notifications from "./settings_notifications"; -import * as stream_edit from "./stream_edit"; -import * as stream_list from "./stream_list"; -import * as unread_ui from "./unread_ui"; +import * as message_lists from "./message_lists.ts"; +import * as settings_notifications from "./settings_notifications.ts"; +import * as stream_edit from "./stream_edit.ts"; +import * as stream_list from "./stream_list.ts"; +import * as unread_ui from "./unread_ui.ts"; export function update_is_muted(sub, value) { sub.is_muted = value; diff --git a/web/src/stream_pill.ts b/web/src/stream_pill.ts index be14111380..6e69135640 100644 --- a/web/src/stream_pill.ts +++ b/web/src/stream_pill.ts @@ -2,12 +2,12 @@ import assert from "minimalistic-assert"; import render_input_pill from "../templates/input_pill.hbs"; -import {$t} from "./i18n"; -import type {InputPillContainer} from "./input_pill"; -import * as peer_data from "./peer_data"; -import * as stream_data from "./stream_data"; -import type {StreamSubscription} from "./sub_store"; -import type {CombinedPill, CombinedPillContainer} from "./typeahead_helper"; +import {$t} from "./i18n.ts"; +import type {InputPillContainer} from "./input_pill.ts"; +import * as peer_data from "./peer_data.ts"; +import * as stream_data from "./stream_data.ts"; +import type {StreamSubscription} from "./sub_store.ts"; +import type {CombinedPill, CombinedPillContainer} from "./typeahead_helper.ts"; export type StreamPill = { type: "stream"; diff --git a/web/src/stream_popover.js b/web/src/stream_popover.js index a1c2127a5b..e7cda5742a 100644 --- a/web/src/stream_popover.js +++ b/web/src/stream_popover.js @@ -6,31 +6,31 @@ import render_inline_decorated_stream_name from "../templates/inline_decorated_s import render_move_topic_to_stream from "../templates/move_topic_to_stream.hbs"; import render_left_sidebar_stream_actions_popover from "../templates/popovers/left_sidebar/left_sidebar_stream_actions_popover.hbs"; -import * as blueslip from "./blueslip"; -import * as browser_history from "./browser_history"; -import * as composebox_typeahead from "./composebox_typeahead"; -import * as dialog_widget from "./dialog_widget"; -import * as dropdown_widget from "./dropdown_widget"; -import * as hash_util from "./hash_util"; -import {$t, $t_html} from "./i18n"; -import * as message_edit from "./message_edit"; -import * as message_lists from "./message_lists"; -import * as message_view from "./message_view"; -import * as popover_menus from "./popover_menus"; -import {left_sidebar_tippy_options} from "./popover_menus"; -import {web_channel_default_view_values} from "./settings_config"; -import * as settings_data from "./settings_data"; -import * as stream_color from "./stream_color"; -import * as stream_data from "./stream_data"; -import * as stream_settings_api from "./stream_settings_api"; -import * as stream_settings_components from "./stream_settings_components"; -import * as stream_settings_ui from "./stream_settings_ui"; -import * as sub_store from "./sub_store"; -import * as ui_report from "./ui_report"; -import * as ui_util from "./ui_util"; -import * as unread_ops from "./unread_ops"; -import {user_settings} from "./user_settings"; -import * as util from "./util"; +import * as blueslip from "./blueslip.ts"; +import * as browser_history from "./browser_history.ts"; +import * as composebox_typeahead from "./composebox_typeahead.ts"; +import * as dialog_widget from "./dialog_widget.ts"; +import * as dropdown_widget from "./dropdown_widget.ts"; +import * as hash_util from "./hash_util.ts"; +import {$t, $t_html} from "./i18n.ts"; +import * as message_edit from "./message_edit.ts"; +import * as message_lists from "./message_lists.ts"; +import * as message_view from "./message_view.ts"; +import * as popover_menus from "./popover_menus.ts"; +import {left_sidebar_tippy_options} from "./popover_menus.ts"; +import {web_channel_default_view_values} from "./settings_config.ts"; +import * as settings_data from "./settings_data.ts"; +import * as stream_color from "./stream_color.ts"; +import * as stream_data from "./stream_data.ts"; +import * as stream_settings_api from "./stream_settings_api.ts"; +import * as stream_settings_components from "./stream_settings_components.ts"; +import * as stream_settings_ui from "./stream_settings_ui.js"; +import * as sub_store from "./sub_store.ts"; +import * as ui_report from "./ui_report.ts"; +import * as ui_util from "./ui_util.ts"; +import * as unread_ops from "./unread_ops.ts"; +import {user_settings} from "./user_settings.ts"; +import * as util from "./util.ts"; // In this module, we manage stream popovers // that pop up from the left sidebar. let stream_popover_instance = null; diff --git a/web/src/stream_settings_api.ts b/web/src/stream_settings_api.ts index 30fe753b94..d69d91c1d1 100644 --- a/web/src/stream_settings_api.ts +++ b/web/src/stream_settings_api.ts @@ -1,9 +1,9 @@ import assert from "minimalistic-assert"; -import * as channel from "./channel"; -import * as settings_ui from "./settings_ui"; -import type {StreamProperties, StreamSubscription} from "./sub_store"; -import * as sub_store from "./sub_store"; +import * as channel from "./channel.ts"; +import * as settings_ui from "./settings_ui.ts"; +import type {StreamProperties, StreamSubscription} from "./sub_store.ts"; +import * as sub_store from "./sub_store.ts"; export type SubData = { [Property in keyof StreamProperties]: { diff --git a/web/src/stream_settings_components.ts b/web/src/stream_settings_components.ts index a936255f35..2e1c57b0e3 100644 --- a/web/src/stream_settings_components.ts +++ b/web/src/stream_settings_components.ts @@ -6,22 +6,22 @@ import render_unsubscribe_private_stream_modal from "../templates/confirm_dialog import render_inline_decorated_stream_name from "../templates/inline_decorated_stream_name.hbs"; import render_selected_stream_title from "../templates/stream_settings/selected_stream_title.hbs"; -import * as channel from "./channel"; -import * as confirm_dialog from "./confirm_dialog"; -import * as dropdown_widget from "./dropdown_widget"; -import type {DropdownWidget} from "./dropdown_widget"; -import * as hash_util from "./hash_util"; -import {$t, $t_html} from "./i18n"; -import * as loading from "./loading"; -import * as overlays from "./overlays"; -import * as peer_data from "./peer_data"; -import * as settings_config from "./settings_config"; -import * as settings_data from "./settings_data"; -import {current_user} from "./state_data"; -import * as stream_ui_updates from "./stream_ui_updates"; -import type {StreamSubscription} from "./sub_store"; -import * as ui_report from "./ui_report"; -import * as user_groups from "./user_groups"; +import * as channel from "./channel.ts"; +import * as confirm_dialog from "./confirm_dialog.ts"; +import * as dropdown_widget from "./dropdown_widget.ts"; +import type {DropdownWidget} from "./dropdown_widget.ts"; +import * as hash_util from "./hash_util.ts"; +import {$t, $t_html} from "./i18n.ts"; +import * as loading from "./loading.ts"; +import * as overlays from "./overlays.ts"; +import * as peer_data from "./peer_data.ts"; +import * as settings_config from "./settings_config.ts"; +import * as settings_data from "./settings_data.ts"; +import {current_user} from "./state_data.ts"; +import * as stream_ui_updates from "./stream_ui_updates.ts"; +import type {StreamSubscription} from "./sub_store.ts"; +import * as ui_report from "./ui_report.ts"; +import * as user_groups from "./user_groups.ts"; export function set_right_panel_title(sub: StreamSubscription): void { let title_icon_color = "#333333"; diff --git a/web/src/stream_settings_containers.ts b/web/src/stream_settings_containers.ts index ccd8764028..4191a362e0 100644 --- a/web/src/stream_settings_containers.ts +++ b/web/src/stream_settings_containers.ts @@ -1,7 +1,7 @@ import $ from "jquery"; import assert from "minimalistic-assert"; -import type {StreamSubscription} from "./sub_store"; +import type {StreamSubscription} from "./sub_store.ts"; export function get_edit_container(sub: StreamSubscription): JQuery { assert(sub !== undefined, "Stream subscription is undefined."); diff --git a/web/src/stream_settings_data.ts b/web/src/stream_settings_data.ts index d7cb664a8a..f106dba912 100644 --- a/web/src/stream_settings_data.ts +++ b/web/src/stream_settings_data.ts @@ -1,14 +1,14 @@ -import * as hash_util from "./hash_util"; -import * as peer_data from "./peer_data"; -import type {User} from "./people"; -import * as settings_config from "./settings_config"; -import {current_user} from "./state_data"; -import * as stream_data from "./stream_data"; -import type {StreamSpecificNotificationSettings, StreamSubscription} from "./sub_store"; -import * as sub_store from "./sub_store"; -import * as timerender from "./timerender"; -import {user_settings} from "./user_settings"; -import * as util from "./util"; +import * as hash_util from "./hash_util.ts"; +import * as peer_data from "./peer_data.ts"; +import type {User} from "./people.ts"; +import * as settings_config from "./settings_config.ts"; +import {current_user} from "./state_data.ts"; +import * as stream_data from "./stream_data.ts"; +import type {StreamSpecificNotificationSettings, StreamSubscription} from "./sub_store.ts"; +import * as sub_store from "./sub_store.ts"; +import * as timerender from "./timerender.ts"; +import {user_settings} from "./user_settings.ts"; +import * as util from "./util.ts"; export type SettingsSubscription = StreamSubscription & { date_created_string: string; diff --git a/web/src/stream_settings_ui.js b/web/src/stream_settings_ui.js index c2c6a25c48..20a1803b6b 100644 --- a/web/src/stream_settings_ui.js +++ b/web/src/stream_settings_ui.js @@ -8,39 +8,39 @@ import render_browse_streams_list_item from "../templates/stream_settings/browse import render_stream_settings from "../templates/stream_settings/stream_settings.hbs"; import render_stream_settings_overlay from "../templates/stream_settings/stream_settings_overlay.hbs"; -import * as blueslip from "./blueslip"; -import * as browser_history from "./browser_history"; -import * as components from "./components"; -import * as compose_banner from "./compose_banner"; -import * as compose_recipient from "./compose_recipient"; -import * as compose_state from "./compose_state"; -import * as hash_parser from "./hash_parser"; -import * as hash_util from "./hash_util"; -import {$t} from "./i18n"; -import * as keydown_util from "./keydown_util"; -import * as message_lists from "./message_lists"; -import * as message_live_update from "./message_live_update"; -import * as message_view_header from "./message_view_header"; -import * as narrow_state from "./narrow_state"; -import * as overlays from "./overlays"; -import {postprocess_content} from "./postprocess_content"; -import * as resize from "./resize"; -import * as scroll_util from "./scroll_util"; -import * as search_util from "./search_util"; -import * as settings_config from "./settings_config"; -import * as settings_data from "./settings_data"; -import {current_user, realm} from "./state_data"; -import * as stream_create from "./stream_create"; -import * as stream_data from "./stream_data"; -import * as stream_edit from "./stream_edit"; -import * as stream_edit_subscribers from "./stream_edit_subscribers"; -import * as stream_edit_toggler from "./stream_edit_toggler"; -import * as stream_list from "./stream_list"; -import * as stream_settings_api from "./stream_settings_api"; -import * as stream_settings_components from "./stream_settings_components"; -import * as stream_settings_data from "./stream_settings_data"; -import * as stream_ui_updates from "./stream_ui_updates"; -import * as sub_store from "./sub_store"; +import * as blueslip from "./blueslip.ts"; +import * as browser_history from "./browser_history.ts"; +import * as components from "./components.ts"; +import * as compose_banner from "./compose_banner.ts"; +import * as compose_recipient from "./compose_recipient.ts"; +import * as compose_state from "./compose_state.ts"; +import * as hash_parser from "./hash_parser.ts"; +import * as hash_util from "./hash_util.ts"; +import {$t} from "./i18n.ts"; +import * as keydown_util from "./keydown_util.ts"; +import * as message_lists from "./message_lists.ts"; +import * as message_live_update from "./message_live_update.ts"; +import * as message_view_header from "./message_view_header.ts"; +import * as narrow_state from "./narrow_state.ts"; +import * as overlays from "./overlays.ts"; +import {postprocess_content} from "./postprocess_content.ts"; +import * as resize from "./resize.ts"; +import * as scroll_util from "./scroll_util.ts"; +import * as search_util from "./search_util.ts"; +import * as settings_config from "./settings_config.ts"; +import * as settings_data from "./settings_data.ts"; +import {current_user, realm} from "./state_data.ts"; +import * as stream_create from "./stream_create.ts"; +import * as stream_data from "./stream_data.ts"; +import * as stream_edit from "./stream_edit.ts"; +import * as stream_edit_subscribers from "./stream_edit_subscribers.ts"; +import * as stream_edit_toggler from "./stream_edit_toggler.ts"; +import * as stream_list from "./stream_list.ts"; +import * as stream_settings_api from "./stream_settings_api.ts"; +import * as stream_settings_components from "./stream_settings_components.ts"; +import * as stream_settings_data from "./stream_settings_data.ts"; +import * as stream_ui_updates from "./stream_ui_updates.ts"; +import * as sub_store from "./sub_store.ts"; export function is_sub_already_present(sub) { return stream_ui_updates.row_for_stream_id(sub.stream_id).length > 0; diff --git a/web/src/stream_topic_history.ts b/web/src/stream_topic_history.ts index 288bb8ebe0..cee45ae781 100644 --- a/web/src/stream_topic_history.ts +++ b/web/src/stream_topic_history.ts @@ -1,12 +1,12 @@ import assert from "minimalistic-assert"; -import {all_messages_data} from "./all_messages_data"; -import * as echo_state from "./echo_state"; -import {FoldDict} from "./fold_dict"; -import * as message_util from "./message_util"; -import * as sub_store from "./sub_store"; -import type {StreamSubscription} from "./sub_store"; -import * as unread from "./unread"; +import {all_messages_data} from "./all_messages_data.ts"; +import * as echo_state from "./echo_state.ts"; +import {FoldDict} from "./fold_dict.ts"; +import * as message_util from "./message_util.ts"; +import * as sub_store from "./sub_store.ts"; +import type {StreamSubscription} from "./sub_store.ts"; +import * as unread from "./unread.ts"; // stream_id -> PerStreamHistory object const stream_dict = new Map(); diff --git a/web/src/stream_topic_history_util.ts b/web/src/stream_topic_history_util.ts index 23a3278ba3..aad50f6693 100644 --- a/web/src/stream_topic_history_util.ts +++ b/web/src/stream_topic_history_util.ts @@ -1,8 +1,8 @@ import assert from "minimalistic-assert"; import {z} from "zod"; -import * as channel from "./channel"; -import * as stream_topic_history from "./stream_topic_history"; +import * as channel from "./channel.ts"; +import * as stream_topic_history from "./stream_topic_history.ts"; const stream_topic_history_response_schema = z.object({ topics: z.array( diff --git a/web/src/stream_ui_updates.ts b/web/src/stream_ui_updates.ts index 32e1433503..84b68fb903 100644 --- a/web/src/stream_ui_updates.ts +++ b/web/src/stream_ui_updates.ts @@ -6,20 +6,20 @@ import render_announce_stream_checkbox from "../templates/stream_settings/announ import render_stream_privacy_icon from "../templates/stream_settings/stream_privacy_icon.hbs"; import render_stream_settings_tip from "../templates/stream_settings/stream_settings_tip.hbs"; -import * as hash_parser from "./hash_parser"; -import {$t} from "./i18n"; -import * as settings_components from "./settings_components"; -import * as settings_config from "./settings_config"; -import * as settings_data from "./settings_data"; -import * as settings_org from "./settings_org"; -import {current_user, realm} from "./state_data"; -import * as stream_data from "./stream_data"; -import * as stream_edit_toggler from "./stream_edit_toggler"; -import * as stream_settings_containers from "./stream_settings_containers"; -import type {SettingsSubscription} from "./stream_settings_data"; -import * as sub_store from "./sub_store"; -import type {StreamSubscription} from "./sub_store"; -import * as util from "./util"; +import * as hash_parser from "./hash_parser.ts"; +import {$t} from "./i18n.ts"; +import * as settings_components from "./settings_components.ts"; +import * as settings_config from "./settings_config.ts"; +import * as settings_data from "./settings_data.ts"; +import * as settings_org from "./settings_org.ts"; +import {current_user, realm} from "./state_data.ts"; +import * as stream_data from "./stream_data.ts"; +import * as stream_edit_toggler from "./stream_edit_toggler.ts"; +import * as stream_settings_containers from "./stream_settings_containers.ts"; +import type {SettingsSubscription} from "./stream_settings_data.ts"; +import * as sub_store from "./sub_store.ts"; +import type {StreamSubscription} from "./sub_store.ts"; +import * as util from "./util.ts"; export function row_for_stream_id(stream_id: number): JQuery { return $(`.stream-row[data-stream-id='${CSS.escape(stream_id.toString())}']`); diff --git a/web/src/sub_store.ts b/web/src/sub_store.ts index ffb6d51573..69c31def58 100644 --- a/web/src/sub_store.ts +++ b/web/src/sub_store.ts @@ -1,13 +1,13 @@ import {z} from "zod"; -import * as blueslip from "./blueslip"; +import * as blueslip from "./blueslip.ts"; import type { never_subscribed_stream_schema, stream_properties_schema, stream_schema, stream_specific_notification_settings_schema, -} from "./stream_types"; -import {api_stream_subscription_schema} from "./stream_types"; +} from "./stream_types.ts"; +import {api_stream_subscription_schema} from "./stream_types.ts"; export type Stream = z.infer; export type StreamSpecificNotificationSettings = z.infer< diff --git a/web/src/submessage.ts b/web/src/submessage.ts index 4972d0e2b4..f5ba8e68b2 100644 --- a/web/src/submessage.ts +++ b/web/src/submessage.ts @@ -1,14 +1,14 @@ import {z} from "zod"; -import * as blueslip from "./blueslip"; -import * as channel from "./channel"; -import type {MessageList} from "./message_list"; -import * as message_store from "./message_store"; -import type {Message} from "./message_store"; -import type {PollWidgetOutboundData} from "./poll_widget"; -import {todo_widget_extra_data_schema} from "./todo_widget"; -import type {TodoWidgetOutboundData} from "./todo_widget"; -import * as widgetize from "./widgetize"; +import * as blueslip from "./blueslip.ts"; +import * as channel from "./channel.ts"; +import type {MessageList} from "./message_list.ts"; +import * as message_store from "./message_store.ts"; +import type {Message} from "./message_store.ts"; +import type {PollWidgetOutboundData} from "./poll_widget.ts"; +import {todo_widget_extra_data_schema} from "./todo_widget.ts"; +import type {TodoWidgetOutboundData} from "./todo_widget.ts"; +import * as widgetize from "./widgetize.ts"; export type Submessage = z.infer; diff --git a/web/src/subscriber_api.ts b/web/src/subscriber_api.ts index bc708c09cb..a13a62c82b 100644 --- a/web/src/subscriber_api.ts +++ b/web/src/subscriber_api.ts @@ -1,6 +1,6 @@ -import * as channel from "./channel"; -import * as people from "./people"; -import type {StreamSubscription} from "./sub_store"; +import * as channel from "./channel.ts"; +import * as people from "./people.ts"; +import type {StreamSubscription} from "./sub_store.ts"; /* This module simply encapsulates our legacy API for subscribing diff --git a/web/src/templates.js b/web/src/templates.js index 2dbcb70d6e..ef4c6553c6 100644 --- a/web/src/templates.js +++ b/web/src/templates.js @@ -1,8 +1,8 @@ -import Handlebars from "handlebars/runtime"; +import Handlebars from "handlebars/runtime.js"; -import * as common from "./common"; -import {default_html_elements, intl} from "./i18n"; -import {postprocess_content} from "./postprocess_content"; +import * as common from "./common.ts"; +import {default_html_elements, intl} from "./i18n.ts"; +import {postprocess_content} from "./postprocess_content.ts"; // Below, we register Zulip-specific extensions to the Handlebars API. // diff --git a/web/src/theme.ts b/web/src/theme.ts index 3de4cab6cc..f9350b6930 100644 --- a/web/src/theme.ts +++ b/web/src/theme.ts @@ -1,10 +1,10 @@ import $ from "jquery"; -import {localstorage} from "./localstorage"; -import * as message_lists from "./message_lists"; -import * as realm_logo from "./realm_logo"; -import * as settings_config from "./settings_config"; -import {user_settings} from "./user_settings"; +import {localstorage} from "./localstorage.ts"; +import * as message_lists from "./message_lists.ts"; +import * as realm_logo from "./realm_logo.ts"; +import * as settings_config from "./settings_config.ts"; +import {user_settings} from "./user_settings.ts"; const ls = localstorage(); diff --git a/web/src/thumbnail.ts b/web/src/thumbnail.ts index 0390c5999f..ac32c57207 100644 --- a/web/src/thumbnail.ts +++ b/web/src/thumbnail.ts @@ -1,7 +1,7 @@ import type {z} from "zod"; -import {realm} from "./state_data"; -import type {thumbnail_format_schema} from "./state_data"; +import {realm} from "./state_data.ts"; +import type {thumbnail_format_schema} from "./state_data.ts"; type ThumbnailFormat = z.infer; diff --git a/web/src/timerender.ts b/web/src/timerender.ts index 177bbd619f..5f68ae9235 100644 --- a/web/src/timerender.ts +++ b/web/src/timerender.ts @@ -10,11 +10,11 @@ import $ from "jquery"; import render_markdown_time_tooltip from "../templates/markdown_time_tooltip.hbs"; -import {$t} from "./i18n"; -import {difference_in_calendar_days, get_offset, start_of_day} from "./time_zone_util"; -import {parse_html} from "./ui_util"; -import {user_settings} from "./user_settings"; -import * as util from "./util"; +import {$t} from "./i18n.ts"; +import {difference_in_calendar_days, get_offset, start_of_day} from "./time_zone_util.ts"; +import {parse_html} from "./ui_util.ts"; +import {user_settings} from "./user_settings.ts"; +import * as util from "./util.ts"; let next_timerender_id = 0; diff --git a/web/src/tippyjs.ts b/web/src/tippyjs.ts index 8079251829..84d69630be 100644 --- a/web/src/tippyjs.ts +++ b/web/src/tippyjs.ts @@ -7,14 +7,14 @@ import render_change_visibility_policy_button_tooltip from "../templates/change_ import render_org_logo_tooltip from "../templates/org_logo_tooltip.hbs"; import render_tooltip_templates from "../templates/tooltip_templates.hbs"; -import {$t} from "./i18n"; -import * as people from "./people"; -import * as popovers from "./popovers"; -import * as settings_config from "./settings_config"; -import * as stream_data from "./stream_data"; -import * as ui_util from "./ui_util"; -import {user_settings} from "./user_settings"; -import * as util from "./util"; +import {$t} from "./i18n.ts"; +import * as people from "./people.ts"; +import * as popovers from "./popovers.ts"; +import * as settings_config from "./settings_config.ts"; +import * as stream_data from "./stream_data.ts"; +import * as ui_util from "./ui_util.ts"; +import {user_settings} from "./user_settings.ts"; +import * as util from "./util.ts"; // For tooltips without data-tippy-content, we use the HTML content of // a