카테고리 그룹

:discourse2: 요약 카테고리 그룹은 카테고리를 그룹에 할당할 수 있으며, 이 그룹은 카테고리 페이지에서 카테고리를 정렬하고 접는 데 사용됩니다.
:eyeglasses: 미리보기 Discourse Theme Creator에서 미리보기
:hammer_and_wrench: 리포지토리 링크 https://github.com/discourse/discourse-category-groups-component
:open_book: Discourse 테마를 처음 사용하시나요? Discourse 테마 사용 입문가이드

이 테마 컴포넌트 설치

기능

:information_source: 참고할 중요한 사항:

  • 이 테마 컴포넌트는 사이트 설정 desktop category page styleboxes with subcategories로 설정되어 있을 때만 작동합니다(해당 카테고리 페이지 템플릿을 대체하기 때문).

  • 카테고리 접기는 브라우저의 로컬 스토리지를 사용하므로, 접힌 상태는 다른 기기 간에 기억되지 않습니다.

설정

이름 설명
category groups 그룹이 구성되는 방식입니다. 형식: 그룹 이름: category-slug, extra-link-id, category-slug-2 (카테고리 슬러그는 URL에서 확인되는 카테고리의 이름입니다. 일반적으로 공백 없이 모두 소문자입니다)
extra links 카테고리 목록에 섞어 넣을 수 있는 추가 링크입니다. 렌더링하려면 category_groups 설정에 링크 ID를 추가하세요
show on mobile 모바일에서 접을 수 있는 카테고리 박스 그룹 표시
show ungrouped 다른 그룹에 할당되지 않은 카테고리의 그룹을 표시
fancy styling 추가 스타일링 켜기 (일부 사용자 정의 스타일이 추가되었습니다. 기본값에서 벗어나므로, 자체 테마를 작업 중이라면 이 기능을 비활성화하는 것이 좋습니다)
hide muted subcategories 활성화되면, 음소거된 하위 카테고리가 있는 경우 음소거되지 않은 상위 카테고리가 음소거 섹션에 표시되지 않습니다
테마 번역 기본값
ungrouped_categories_title 기타

:discourse2: 저희가 호스팅을 제공하나요? 테마 컴포넌트는 Pro, Business 및 Enterprise 플랜에서 사용할 수 있습니다.

53개의 좋아요

I’ve just merged a refactor of this component. Functionality should remain the same overall, with some bug fixes.

https://github.com/discourse/discourse-category-groups-component/pull/11

Behind the scenes this uses some modernized Ember, and eliminates template overrides, which can be a little fragile as far as Discourse customizations go.

This should be fixed now

This is fixed now, the groups will no longer apply to the subcategory layouts

I’ve updated this, so category logos should be much more normally sized now

6개의 좋아요

Is it possible to not show subcategories for a particular category? We have a category that’s organized in a particular way with nested subcategories and it’s causing the box to be quite large.

2개의 좋아요

아마도 #customization:theme-component에서 Category Hider를 시도해 볼 수 있습니다.

2개의 좋아요

Can you tell me if it’s possible to apply the category groupings to the sidebar? If not, I would like to put this in as a feature request. Thanks!

1개의 좋아요


There is a problem on my website, subcategories hasn’t space between them.

2개의 좋아요

Thanks for reporting it, an update should fix it now (fixed in UX: include gap for subcategories by awesomerobot · Pull Request #19 · discourse/discourse-category-groups-component · GitHub).

2개의 좋아요

It’s not possible, the sidebar would need a bigger change in Discourse to allow for this (request noted!)

2개의 좋아요

Will be awesome if this grouping will be customizable by user, some people in our community wanted that.

Yeah, this needs a plugin, but a good idea I think

Any idea why the category width is so skinny? Is there a way to fix this?

2개의 좋아요

is this in the Mint theme? I’ve just made a minor update that should fix it — there was a slight conflict between the CSS of that theme and this component

3개의 좋아요

Yeah it was the mint, thank you

2개의 좋아요

How do I prevent the boxes being outlined with the category colour? I’ve tried forking it, adding css, and also changing the <li style in the categories-groups.hbs

(Note that I am a dabbler, not a trained developer)

3개의 좋아요

You can add a little CSS to your theme to remove the colorful borders:

.category-boxes .category-box {
  border-left: 2px solid var(--primary-low) !important;
}

or if you have the “fancy styling” setting turned on:

.custom-categories-groups .category-box {
    border: 2px solid var(--primary-low) !important;
}

1개의 좋아요

Thanks Kris,

It appears I’m having a bigger problem. For some reason, whenever I try to update the Theme component, it doesn’t pick up the changes at all. So my css was good, it just wasn’t being loaded. Not something for this thread, I’ll have a search around to see if there is something dumb I’m doing

1개의 좋아요

Would it be possible to have the fancy styling boxes with a latest section below the categories? In essence I want to do that same thing that the “Modern Categories + Group Boxes” component does in the Air Theme. You can select Categories with Latest for the desktop view and latest displays below the categories.

Im trying to edit my own version of the CSS but im no expert. Would this be an easy thing to do or might it be out of my skill set?

1개의 좋아요

저희는 카테고리가 많고, 활성화된 하위 카테고리까지 더해져 랜딩 페이지가 매우 혼잡해져 사용자가 관심 있는 항목을 찾기 어려운 상황을 겪고 있습니다.

이로 인해 특정 관심사 영역(유저 그룹)에 속한 사용자에게 더 정밀하게 맞춘 방식으로 카테고리 그룹 랜딩 페이지를 커스터마이징하고자 합니다.

따라서 각 카테고리 그룹에 대해 가시성(visibility) 옵션을 추가하는 것을 제안합니다. 이 옵션이 정의된 경우, 해당 카테고리 그룹은 설정에서 활성화된 유저 그룹에만 표시되도록 할 수 있습니다.

이 모든 것을 설명하기 위해 풀 리퀘스트를 생성했습니다. 이 옵션에 대해 어떻게 생각하시는지 알려주세요. 이 기능을 사용하시겠습니까? 여러분의 Discourse 사이트에 적용할 수 있을까요?

p.s. 이 제안된 새로운 옵션은 대체 액세스 제어로 고려되어서는 안 됩니다. 이는 단순히 로그인된 사용자의 그룹 소속에 따라 어떤 카테고리 그룹이 표시될지를 제어하는 것입니다. 기존 권한은 여전히 유효합니다.

1개의 좋아요

최근 Discourse 업데이트 이후로 표시가 안 되는 것 같습니다. 이 TC가 작동하려면 업데이트가 필요할 수도 있습니다.

(게시글이 작성자에 의해 삭제되었습니다)

호라이즌에서는 작동하지 않는 것이 맞나요?

1개의 좋아요