Skip to content
This repository has been archived by the owner on Jul 21, 2019. It is now read-only.

[refs #00611] Add ability to use custom_url in program page #645

Merged
merged 36 commits into from
Sep 3, 2018
Merged

[refs #00611] Add ability to use custom_url in program page #645

merged 36 commits into from
Sep 3, 2018

Conversation

chriscoffee
Copy link
Member

@chriscoffee chriscoffee commented Aug 25, 2018

Hey 👋

This PR should add the ability to add a custom_url for all types on the
program page and fix #611. (I meant to get this in sooner but there's a terrible flu going around the UK at the moment!)

By adding custom_url: "https://example.com/valid-url"in talk/ignite/custom/workshop you'll replace the link with one that's external and opens in a new window.

For what is essentially a simple change I also took it upon myself to alter the indenting and remove a number of unused tags. This can be reverted easily if I overstepped here slightly. The following tags weren't used:

</div>
</div>

As a future point I feel like in the future we could probably refactor this template which will probably improve the build performance slightly but that's a future consideration. (Average CPU time duration for that template is ~53s)


This change is Reviewable

mattstratton and others added 6 commits October 19, 2017 10:44
This is still a POC - the icons used can be replaced with something different.

Please consider options at http://fontawesome.io/icons/ for other choices.

Signed-off-by: Matt Stratton <[email protected]>
The existing footer takes the current time (build time), casts it to a
string, and compares it with the CFP start/end times which are also
being re-cast to strings here (twice!).

In order to allow us to use timezones as part of our comparison and not
have the formatting involved in comparisons, use the `time` template
function and directly compare against `now` without typecasting.

ref https://gohugo.io/functions/time/
ref https://gohugo.io/functions/now/
Many existing template partials take the current time (build time), cast
it to a string, and compares it with the times from the event data (ex.
start/end times) which are also being re-cast to strings here (twice!).

In order to allow us to use timezones as part of our comparison and not
have the formatting involved in comparisons, use the `time` template
function and directly compare against `now` without typecasting.

ref https://gohugo.io/functions/time/
ref https://gohugo.io/functions/now/
reduce the overall rendering time by ~75% via the following:
- cache the entirely-static footer partial
- eliminate looping over all talks in speaker page
- eliminate looping over all speakers in talk page
Add ability to add a custom_url type for all types of talk on the
program page. Adding custom_url: "https://valid.url.co.uk" will result
in the link on the schedule being opened in another window.

I also took it upon myself to change the indenting in the single.html
file but this can be reverted.
@bridgetkromhout
Copy link
Contributor

Hey, thanks for getting started on this! Please don't open a new window for people - people can choose to open a new window if they want, but as a stylistic choice we don't have anything on the site making that call for the end users.

@mattstratton
Copy link
Member

@chriscoffee Because of some other changes merged, I think you want to rebase and submit the PR again (also please see @bridgetkromhout request as well). Thanks!

mattstratton and others added 17 commits August 31, 2018 15:34
Signed-off-by: Matt Stratton <[email protected]>
Signed-off-by: Matt Stratton <[email protected]>
Signed-off-by: Matt Stratton <[email protected]>
Signed-off-by: Matt Stratton <[email protected]>
The "powerpoint" imagery doesn't cover most cases, and being specific to a file format is weird. I like the "screen" one in the pro pack, but if we don't go with that, I'd prefer "document".
Replacing the powerpoint icon with a more generic text one.
Requires the page frontmatter parameter “icons” to be set to “true” on the `program.md` file for an event for video and/or slide links to show in the progam page

Signed-off-by: Matt Stratton <[email protected]>
Bower with gulp is deprecated and causing build issues

Signed-off-by: Matt Stratton <[email protected]>
Bower with gulp is deprecated and causing build issues

Signed-off-by: Matt Stratton <[email protected]>
Add display of videos and slides to program page
mattstratton and others added 4 commits September 3, 2018 15:24
Add ability to add a custom_url type for all types of talk on the
program page. Adding custom_url: "https://valid.url.co.uk" will result
in the link on the schedule being opened in another window.

I also took it upon myself to change the indenting in the single.html
file but this can be reverted.
…nto chriscoffee/tkt-00611

Signed-off-by: Matt Stratton <[email protected]>

# Conflicts:
#	layouts/program/single.html
@mattstratton
Copy link
Member

I did my best to merge the existing changes with your updates here, @chriscoffee - let's see if it works!

Manual merge with existing updates. Also updated 2017 Ponyville to use this (first day open space #2)

Signed-off-by: Matt Stratton <[email protected]>
The theme has built CSS in it, so just updating the SCSS doesn’t get you all the way there :)

Signed-off-by: Matt Stratton <[email protected]>
@mattstratton
Copy link
Member

Seems to be working - can't get a build out of netlify right now (it's hung) but if we merge this, we can see it on dev.devopsdays.org and check it out there.

I removed the "open in new window/tab" per @bridgetkromhout request.

@mattstratton mattstratton merged commit dcae6a6 into devopsdays:master Sep 3, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Allow URL link on "custom" program type
4 participants