zulip/static/templates/stream_settings
YashRE42 ca57400771 stream_create: Always insert change-stream-privacy button.
Previously, if an admin created a private stream with shared history
or a private stream with protected history, they would see the general
tab for that stream in the right side of the subscriptions_overlay as
expected, but, they would not see the pencil button to change stream
privacy unless they clicked a different stream and came back.

The reason for this has to do with how we receive events when we
create a sub. We first get an event with type "stream" and op
"create", we then get an event with type "subscription" and op "add"
ie we create the stream and then sub ourselves to it. Now, we render
`stream_settings.hbs` while handling the "stream create" event, at
this time we pass `can_change_stream_permissions` as false since
`(!sub.invite_only || sub.subscribed)` is false because we're not
subscribed yet. This causes us to skip the insertion of the
"change-stream-privacy" block which is a problem because when we're
handling the "subscription add" event, we run
`stream_ui_updates.update_change_stream_privacy_settings(sub)` which
tries to show the element via `.show()` but can't since the element
does not exist and as a result the admin user does not see the pencil
edit button.

This commit fixes the above bug by changing the template such that we
always insert the button, but conditionally apply
`style="display:none"`.

Fixes: #20345.
2021-11-24 10:49:29 -08:00
..
browse_streams_list.hbs stream settings: Move stream list templates to stream_settings. 2021-07-19 10:54:11 -07:00
browse_streams_list_item.hbs stream settings: Move stream list templates to stream_settings. 2021-07-19 10:54:11 -07:00
change_stream_info_modal.hbs change_stream_info_modal: Migrate modal to dialog_widget. 2021-11-08 17:27:27 -08:00
stream_creation_form.hbs stream_settings: Remove grey-box from personal tab & stream create. 2021-11-23 14:10:49 -08:00
stream_description.hbs
stream_member_list_entry.hbs streams: Show "hidden" in subscriber-list when email is not accessible. 2021-11-09 13:26:31 +05:30
stream_members.hbs templates: Prevent dangling end tags. 2021-11-23 15:55:54 -08:00
stream_permission_description.hbs stream_data: Rephrase descriptions of stream permissons. 2021-09-14 11:29:32 -07:00
stream_privacy_icon.hbs stream settings: Move stream privacy icon template to stream_settings. 2021-07-18 11:36:39 -07:00
stream_settings.hbs stream_create: Always insert change-stream-privacy button. 2021-11-24 10:49:29 -08:00
stream_settings_checkbox.hbs css: Delete now unused subscription-control-label class. 2021-11-23 14:50:00 -08:00
stream_settings_overlay.hbs subscription_settings: Make the `+` button more visible. 2021-10-12 15:38:47 -07:00
stream_subscription_request_result.hbs stream settings: Move subscription_result template to stream_settings. 2021-07-19 10:54:11 -07:00
stream_types.hbs stream_types: Remove new-style class in stream_types.hbs. 2021-11-23 14:11:35 -08:00
subscriber_count.hbs stream settings: Move small independent templates to stream_settings. 2021-07-19 10:54:11 -07:00
subscription_setting_icon.hbs stream settings: Move small independent templates to stream_settings. 2021-07-19 10:54:11 -07:00