Custom sidebar sections being tested on meta

:slight_smile: Sorry, I wasn’t referring to all users necessarily, but my users do prefer that. They’re migrated from a large established forum that also opened external links in a new tab by default.

Also, given that I have other links in the custom section that do get opened in the same tab, the inconsistency with /my/* links is a bit weird for users, who don’t know or care about whether that sort of link requires special handling.

3 Likes

And that can be translated to those who are complaining :wink:

There is another point of view too — how often are users using /my-links? I’m meaning is there any real reason put those links in the sidebar and make it longer, longer and even a bit longer? We have already links to /my-section on more personal menu


3 Likes

If you’ve enabled the custom sidebar option via settings enable custom sidebar sections and want to customise the sidebar, look for the “+” icon at the bottom of the sidebar.

Took me about 10 minutes of scrambling around various settings screens to realise it’s part of the main user interface. :facepalm:

6 Likes

Definitely. There was a huge discussion as soon as the forum was migrated, “Where is the list of threads that I’m subscribed to?”. To be honest, not even I found the links to Tracked and Watched topics at its strange location under /my/preferences/tracking . I also needed to add a sidebar link to a custom search query to help users find the threads imported from the old forum that they had participated in (which opens in the same tab since it’s not a /my/ link).

2 Likes

Linking to admin pages shows the error: An error occurred: Sidebar urls value is not valid

Why would this not be allowed?

3 Likes

Hi, are there any updates here :face_with_monocle:

I want to make a default sidebar for trust levels 1 and 2 so all categories can be present.

2 Likes

This is now an option for admins in the custom section modal:

We don’t have a way to reorder sections yet, I believe we’re going to focus on customizing the “Community” section first.

9 Likes

Excellent, thanks for the update.

At present I’m holding off from enabling this with our forum, for the following reasons:

  • It would end up with us creating similar duplicated sections as we’re unable to remove sections
  • It’s not possible to reorder the sections

Will keep an eye on this thread. :eyes:

7 Likes

It’s awesome that there is now the option “Make this section public and visible to everyone”, but I do have some feedback,

  • “public and visible to everyone” means “visible to TL0 and up”, i.e. the usual Discourse meaning of “everyone” here is not being followed.
  • it would be really really really cool if this actually would be public and visible to everyone.
  • checking this box also implies that other admins are able to edit the section (which is great!!) but maybe not always expected, so it might be good to make that explicit.

(Oh, and really weird things happen if one admin checks the box and another one unchecks it, it seems like the checkbox state is not updated between clients and the sidebar is not being refreshed. Repro: admin 1 creates a section and checks the box, admin 2 edits the section and unchecks the box, admin 2 edits the section and checks it again, yields a FAILED error)

11 Likes

I’m not quite following this one. Can you give an example?

2 Likes

Hello,

It seems the latest update is broke the site. Only the preload splash page shows up.
I think it is maybe because the js.sidebar.sections.custom.links.value string is removed from locale but in the other languages is still there. FIX: display validation under custom sidebar fields (#20772) · discourse/discourse@4047073 · GitHub

Here HivatkozĂĄs means Link.

I tried to override this string and also try safe mode or disable the custom sidebar sections but nothing worked. :confused:

Thanks :slightly_smiling_face:

4 Likes

Sorry that this change caused troubles :frowning: Do you have access to rails console for your instance?

If yes, maybe you can check override translations like:

TranslationOverride.where(translation_key: "js.sidebar.sections.custom.links.value")

and maybe delete them like

TranslationOverride.where(translation_key: "js.sidebar.sections.custom.links.value").delete_all
4 Likes

Thanks Kris :slightly_smiling_face: I tried it in rails but I am not sure I just need to copy and paste it?

If I paste:

TranslationOverride.where(translation_key: "js.sidebar.sections.custom.links.value")

Result:
[]


TranslationOverride.where(translation_key: "js.sidebar.sections.custom.links.value").delete_all

Result:
0

Seems nothing happened. :thinking:

3 Likes

Do you have any results for

TranslationOverride.where(translation_key: "js.sidebar.sections.custom.links.icon")

or

TranslationOverride.where(translation_key: "js.sidebar.sections.custom.links.name")
3 Likes

Only with the second one.

[6] pry(main)> TranslationOverride.where(translation_key: "js.sidebar.sections.custom.links.name")
=> [#<TranslationOverride:0x00007f3ee402a1f0
  id: 4419,
  locale: "hu",
  translation_key: "js.sidebar.sections.custom.links.name",
  value: "NĂ©v",
  created_at: Sat, 04 Feb 2023 03:58:04.239990000 UTC +00:00,
  updated_at: Thu, 09 Mar 2023 08:46:21.254381000 UTC +00:00,
  compiled_js: nil>]
2 Likes

Actually, I replicated that in my local machine :confetti_ball:

What I think happened is that you override text for new translations: js.sidebar.sections.custom.links.name.validation.blank js.sidebar.sections.custom.links.name.validation.maximum

However, like you noticed, other languages than English doesn’t yet have them. Therefore, we have to remove them for now until other locale files are updated:

First let’s display all translation before deleting them, maybe copy and paste them somewhere, so your translations are not permanently lost:

TranslationOverride.where("translation_key like 'js.sidebar.sections.custom.links%'")

To delete them run:

TranslationOverride.where("translation_key like 'js.sidebar.sections.custom.links%'").delete_all
4 Likes

Ah, thanks Kris :slightly_smiling_face: Yeah this is happened exactly what you write. I just didn’t realize this will cause any issue If I translate those strings. Now I will wait until Tuesdays update with this :smiley:

Thanks again for your help! This is worked perfectly! :heart:

4 Likes

Awesome, thank you :slight_smile:
Sorry once again for this bug. We will think about solution to protect overrides when other languages are not yet ready.

5 Likes

Don’t worry about it :slightly_smiling_face: I am really glad because this kind of bugs sometimes happens and now thanks to you I learned how to resolve this from rails. :slightly_smiling_face: I think this is a really great thing. Your quick response and solution to this issue is amazed me. :heart: Maybe others will also have this issue and this little conversation can help to resolve it.

Love this idea. I hope this will implement soon. I like test new things and try to find fresh bugs so I always runs the experimental features and keep fresh the site. And this also means that I don’t always wait for language updates. Until this I have to make more attention about translations. :slightly_smiling_face:

5 Likes

Sure thing, @mcwumbly.

My first goal is to move the existing category sections. I’d like to move “(Chat) Channels” to the top, followed by “Categories” and then “Community”

My second goal is to edit the names of those default category sections.

However, if I could create custom sections I’d attempt to recreate what I’ve described in my first and second goal and then I’d want to remove the defaults. Yet that all seems pointless right now cos I’ll just wait for the ability to move category sections and the ability to edit category section titles.

3 Likes