Commit Graph

103 Commits

Author SHA1 Message Date
Joe Mooring 34f3167b79 Update image processing (#1625) 2022-03-25 06:09:41 -07:00
Yannic Haupenthal 94660c34b6 add missing %s 2022-03-03 15:54:06 +01:00
Yannic Haupenthal 325de15e22 fix link to latest release note
since the release notes were moved to GitHub:
https://gohugo.io/news/no-more-releasenotes-here/
2022-03-03 15:54:06 +01:00
Bjørn Erik Pedersen 849a8437fb Merge commit 'c1398b91a9f4c67876b31feb67516b252e654d3c' 2022-02-28 10:37:27 +01:00
Luke Rijk de Waal e8d5180116 requires -> require typo fix (#1666) 2022-02-23 09:15:13 -08:00
John Elliott bd8037d432 Allow images to be cropped without being resized
Introduces the Crop method for image processing which implements gift.CropToSize. Also allows a smartCrop without resizing, and updates the documentation.

Fixes #9499
2022-02-23 10:01:50 +01:00
Joe Mooring 8f8bcdefc0 Add frontmatter param to code-toggle shortcode (#1601)
Closes #1598
2021-12-08 18:51:26 -08:00
Joe Mooring 2d0f38978b Remove blank lines from code-toggle output (#1564) 2021-11-04 07:10:53 -07:00
Bjørn Erik Pedersen ef73ffc3bc Misc config loading fixes
The main motivation behind this is simplicity and correctnes, but the new small config library is also faster:

```
BenchmarkDefaultConfigProvider/Viper-16         	  252418	      4546 ns/op	    2720 B/op	      30 allocs/op
BenchmarkDefaultConfigProvider/Custom-16        	  450756	      2651 ns/op	    1008 B/op	       6 allocs/op
```

Fixes #8633
Fixes #8618
Fixes #8630
Updates #8591
Closes #6680
Closes #5192
2021-06-14 17:00:32 +02:00
Salim B 0c8f2dcb13 Avoid scratch usage 2021-05-03 21:08:23 +02:00
Salim B 696fa92e11 Rename scratch var 2021-05-03 21:08:23 +02:00
Salim B 44193f267d Update usage instructions 2021-05-03 21:08:23 +02:00
Salim B 4230f8fa54 Rename and refactor shortcode 2021-05-03 21:08:23 +02:00
Salim B e9953751ec Strip leading whitespaces 2021-05-03 21:08:23 +02:00
Salim B d61a580103 Add insertpages shortcode
This is an improvement over the `readfiles` shortcode in that it allows to insert content files that contain shortcodes themselves.

This new shortcode is used to fix a regression introduced in https://github.com/gohugoio/hugoDocs/pull/1442 (`new-in` shortcode was not rendered as intended).
2021-05-03 21:08:23 +02:00
Joe Mooring fce835fead Trim newlines from .Inner in the 'code' shortcode
Closes #1437
2021-05-01 00:46:18 +02:00
Joe Mooring 363251a517 Improve presentation of template lookup order (#1382)
Closes #1374
2021-04-14 21:33:50 -07:00
Jessica Huynh 223b80f420 Fix page kinds shortcode not rendering on Taxonomies page (#1158)
* remove trailing space after "terms" in page-kinds shortcode

* use % style shortcode to render page-kinds markdown table
2020-06-25 15:09:56 +09:00
Bjørn Erik Pedersen e9596b2ee1 Merge branch 'temp73' 2020-06-23 19:05:46 +02:00
Christian Oliff 73c31758e0 Fix for broken link again (#1151) 2020-06-18 19:15:17 +09:00
max-re d070672951 Fix broken link (#1144) 2020-06-18 19:10:11 +09:00
Bjørn Erik Pedersen bc0b484d1b Rename taxonomy kinds from taxonomy to term, taxonomyTerm to taxonomy
And we have taken great measures to limit potential site breakage:

* For `disableKinds` and `outputs` we try to map from old to new values if possible, if not we print an ERROR that can be toggled off if not relevant.
* The layout lookup is mostly compatible with more options for the new `term` kind.

That leaves:

* Where queries in site.Pages using taxonomy/taxonomyTerm Kind values as filter.
* Other places where these kind value are used in the templates (classes etc.)

Fixes #6911
Fixes #7395
2020-06-18 09:09:56 +02:00
Bjørn Erik Pedersen ded74f0982 Add Goldmark as the new default markdown handler
This commit adds the fast and CommonMark compliant Goldmark as the new default markdown handler in Hugo.

If you want to continue using BlackFriday as the default for md/markdown extensions, you can use this configuration:

```toml
[markup]
defaultMarkdownHandler="blackfriday"
```

Fixes #5963
Fixes #1778
Fixes #6355
2019-11-23 14:12:24 +01:00
Bjørn Erik Pedersen d087cf3068 Update image docs for 0.58 2019-09-04 17:33:09 +02:00
Bjørn Erik Pedersen 9d6ac714de Fix shortcode 2019-07-27 17:35:00 +02:00
Bjørn Erik Pedersen cfda93bc34 Update gomodules-info.html 2019-07-25 19:53:38 +02:00
Bjørn Erik Pedersen 3fdb45b3cd docs: Add Hugo Modules docs 2019-07-25 13:21:30 +02:00
Rodolfo Carvalho de7ab636bc Use actual width in image processing examples
The image processing examples are rendered within containers with a
'nested-img' parent CSS class, which by default makes images responsive
by resizing them to the size of their containers.

That doesn't work well for the examples as the small images end up
stretched.

Since there can be other images in the same 'nested-img' context, we
keep that class in the parent and set the example images width to auto,
such that they will render with their actual size.

On small screens, larger images will still be sized down via the
max-width property.

Fixes #812
2019-06-18 17:02:21 +02:00
Bjørn Erik Pedersen 0f2bf195ef Adjust shortcodes for 0.55
Took the easy approach.

Fixes #783
2019-04-09 12:33:09 +02:00
Bjørn Erik Pedersen 5ea938ad60 Remove some Scratch 2018-08-29 11:03:31 +02:00
Bjørn Erik Pedersen 8da3572409 Content and images for the 5th birthday blog post 2018-07-04 13:07:31 +02:00
Bjørn Erik Pedersen c5a5250a1b Use the new go-html-template Chroma lexer 2018-04-02 15:07:01 +02:00
Bjørn Erik Pedersen 2de831f4b9 Add the full list of Chroma lexers 2018-04-02 14:44:35 +02:00
Kaushal Modi 6bfc17cfcb Update few links to now point to gohugoio organization repos
Ref: https://github.com/gohugoio/hugoDocs/issues/6
2018-03-16 16:03:32 -04:00
Bjørn Erik Pedersen 7cfd530d24 Revise the archetype docs
Fixes #11
2018-03-07 11:12:28 +01:00
Bjørn Erik Pedersen 0bd5121250 Improve the Netlify versioning docs 2018-02-12 09:31:14 +01:00
Bjørn Erik Pedersen ba51fe66dd Finish the Maintenance section
Closes #339
2018-02-11 14:16:16 +01:00
Didier GEORGIEFF e9b0c710c9 Add latest changes in new spotlight section 2018-02-11 13:36:48 +01:00
Bjørn Erik Pedersen dce236ad12 Wrap up the bundle etc. edits for now
@kaushalmodi we need wait a little with the page-bundles.md -- there are some terms there that I think will confuse more than it helps.
2018-01-31 10:57:42 +01:00
Bjørn Erik Pedersen 6299d6dbb5 Update the imgproc shortcode 2018-01-31 10:19:33 +01:00
Bjørn Erik Pedersen d5e7c03e20 Rework the layouts doc 2018-01-19 10:14:56 +01:00
Bjørn Erik Pedersen ddb7d8fae0 Fix spelling in error message 2018-01-02 14:20:03 +01:00
Bjørn Erik Pedersen a6d39884c4 Add image processing examples 2018-01-02 12:46:11 +01:00
budparr 05aaee8cec Remove background color from code shortcode
Background color is not necessary with Chroma.css
2017-09-30 10:09:31 +02:00
digitalcraftsman 7062ae075b Remove Press and Articles page 2017-07-28 20:19:56 +02:00
Bjørn Erik Pedersen 7440616b1b Add new and simpler quickstart
Fixes #75
2017-07-23 18:43:20 +02:00
Bjørn Erik Pedersen e4824eb3fe Fix the output shortcode and its usage
Passing the shortcode into the Markdown processor just to get pre and code tags does not make much sense.
2017-07-21 13:06:11 +02:00
Bjørn Erik Pedersen 8eef09d270 Add Pygments configuration
Closes #61
2017-07-20 11:51:45 +02:00
Bjørn Erik Pedersen 4e0bca2b1e Remove the needsexamples construct
We need to rework the whole template func docs and, while a good idea, this does not fit into that.
2017-07-16 15:13:35 +02:00
Bjørn Erik Pedersen 29ba55bfe6 Some more copy edits 2017-07-15 13:14:22 +02:00