Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Schedule Block: Ability to style page without speakers and sessions being published #717

Closed
CdrMarks opened this issue Dec 31, 2021 · 2 comments · Fixed by #994
Closed
Labels
[Component] Blocks All custom blocks (Speakers, CrowdCast, Live Schedule, etc) [Component] WC-Post-Types Organizers, Speakers, Sessions, Schedule, Sponsors, Volunteers [Priority] Medium

Comments

@CdrMarks
Copy link
Collaborator

Summary

As a WordCamp Organizer, it's not possible to style the schedule page without temporarily publishing speakers and sessions.

Current state

Steps to reproduce the current behavior:

  1. Draft several speakers and sessions.
  2. Privately publish the schedule page (do not specify specific dates or tracks)
  3. Browse to the Schedule page.
  4. See "No published sessions are assigned to the chosen days and tracks."

Feature request

Add a setting on the Schedule block to "Show unpublished sessions". This setting would only be honored while Schedule page is not published (the status is either draft or private).

Steps to achieve the requested behavior:

  1. Draft several speakers and sessions.
  2. Edit the Schedule page
  3. On the Schedule block, toggle on a the new setting "Show unpublished sessions"
  4. Privately publish the schedule page (do not specify specific dates or tracks)
  5. Browse to the Schedule page.
  6. See the schedule showing published and unpublished sessions.
@CdrMarks CdrMarks added the [Component] Blocks All custom blocks (Speakers, CrowdCast, Live Schedule, etc) label Dec 31, 2021
@iandunn
Copy link
Member

iandunn commented Dec 31, 2021

🤔 , one way to do it without having to add a new setting would be something like this:

if ( all sessions are drafts && current user is admin ) {
  show all the drafts that have times/tracks assigned

  add banner notice on page saying that they're only shown to admins, for styling purposes
}

I'm not sure if that's better than your suggestion, though. I like not having to add extra UI, but without the UI it won't be obvious that you can preview. The UI may also be more reliable than trying to guess.

Another idea might be to have a "preview mode", where you could style it. Maybe show the draft sessions if the Customizer is open? But that wouldn't be obvious for Remote CSS users. We could also show them when Gutenberg's preview mode is active (i.e., a ?preview_id=11242&preview_nonce=foo&preview=true URL).

I don't have any strong opinions.

@ryelle
Copy link
Contributor

ryelle commented Jan 3, 2022

Maybe show the draft sessions if the Customizer is open?

Chiming in just to say that there won't be customizer support in block themes, so we shouldn't rely on this as a solution long-term (it would still work, I think, but would not be the ideal path).

Will sessions show up in the schedule if they're published as private?

TBH, I think we might want to phase out the preview data in the editor- then we could show any status sessions in the editor, but only published sessions on the frontend? Or something like that, since eventually "customization" would happen in the editor, not in custom CSS.

@renintw renintw added [Component] WC-Post-Types Organizers, Speakers, Sessions, Schedule, Sponsors, Volunteers [Priority] Medium labels Apr 12, 2024
renintw pushed a commit that referenced this issue May 13, 2024
)

* WC Post Types: Show private sessions in API response

See #717

* WC Post Types: Show all attached speakers on a session

* Blocks: Speaker Sessions: Show private sessions in speaker block
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
[Component] Blocks All custom blocks (Speakers, CrowdCast, Live Schedule, etc) [Component] WC-Post-Types Organizers, Speakers, Sessions, Schedule, Sponsors, Volunteers [Priority] Medium
4 participants