1
0
mirror of https://github.com/php/web-php.git synced 2026-04-28 17:33:10 +02:00
Commit Graph

183 Commits

Author SHA1 Message Date
Lucas Azevedo b62f99f6de Update navbar design and improve search UI (#1084)
Co-authored-by: Gina Peter Banyard <girgias@php.net>
Co-authored-by: Sergey Panteleev <sergey@php.net>
2024-11-02 17:39:04 +03:00
Sergey Panteleev fcc95652d8 Fix downloads layout on mobile (#1110) 2024-10-30 16:10:52 +03:00
Roy Orbitson 2dcf9c3796 Fuzzy search of docs (#1007) 2024-08-09 12:11:16 +08:00
peterdd d2279651a5 fix #62125 no wrap and scroll for source code examples (#444) 2024-07-05 11:02:30 +03:00
haszi fbe589892a Move contribution links to the bottom of the documentation pages (#973)
Co-authored-by: haszi <haszika80@gmail.com>
2024-04-17 12:48:52 +01:00
haszi 8192a72c76 Add style for captions (#966)
Co-authored-by: haszi <haszika80@gmail.com>
2024-03-17 18:16:16 +00:00
Sergey Panteleev 84a97774b1 Set max-width for news item images 2024-01-16 16:51:59 +03:00
Sergey Panteleev 0831bac8b3 Set max-width for news images (#921) 2024-01-13 00:11:28 +03:00
Andreas Möller 00342c402f Fix: Remove vim instruction (#880) 2023-12-07 15:01:52 +01:00
Tim Düsterhus 2a5e5a44ab Use white-space: pre-wrap for code formatting (#810)
* Use `white-space: pre-wrap` for code formatting

Apparently code formatting is used for the entire user comments. Use
`white-space: pre-wrap` to avoid horizontal scrolling of the plaintext
description.


see 7d4038829e

* Unify `highlight_php()` with PhD

see php/phd@01d6beb366

* Fix markup for notes in add-note.php
2023-08-30 18:40:00 +01:00
alfsb 64efd46488 Remove double underline on abbr (#800)
Co-authored-by: André L F S Bacci <ae@php.net>
2023-08-18 12:34:12 +01:00
Tim Düsterhus 7d4038829e Apply white-space: pre onto the entire code snippet (#801)
This is needed to correctly handle whitespace outside of a `<?php … ?>` portion.

see php/web-php@b7bccc4049
see php/phd@01d6beb366
see php/doc-en#2648
2023-08-16 14:16:16 +01:00
Christoph M. Becker 8463593803 Only "linked" parameters should have pointer cursor (#742)
If a parameter has no target to scroll to, it should not suggest
otherwise by changing the cursor to a pointer.  Since the scrolling is
done via JS, we should also change the cursor via JS.[1]

While we're at it, we also fix the potential JS error where we call the
`.offset()` method on an empty `jQuery` object.

[1] <https://github.com/php/doc-en/issues/2071#issuecomment-1354497367>
2023-08-10 12:55:25 +01:00
Leonardo Poletto 57fe66b12e Fix code blocks overflowing content. (#777) 2023-08-09 11:29:32 -05:00
Javier Eguiluz f71b6c7396 Add woff2 fonts and other font related tweaks (#752)
The following changes are made in this commit:

**(1)** Add the WOFF2 variant of web fonts. [WOFF2 standard](https://w3c.github.io/woff/woff2/) reduces the file sizes significantly. This is important to make our website more accessible to folks with limited Internet connections.

96% of browsers support WOFF2 ([source](https://caniuse.com/?search=woff2)) and we still have WOFF and TTF/OTF/EOT formats for those edge-cases which don't support it.

Real examples of the file size reductions for php.net:

```
Fira Sans Regular: 183 KB (woff) -> 129 KB (woff2) --> 30% reduction in size
Fira Mono Regular:  87 KB (woff) ->  65 KB (woff2) --> 35% reduction in size
```

**(2)** Use `font-display: swap` for web fonts (see [MDN Docs for font-display](https://developer.mozilla.org/en-US/docs/Web/CSS/@font-face/font-display))

This is recommended to not block the rendering the page for a long time if the web font is not available. Again, this is important for folks with suboptimal network connections.

The `swap` value is also the default option in popular font services like [Google Fonts](https://fonts.google.com/).

**(3)** Update the list of alternative font families.

I updated the sans-serif and mono font stack used in the design. The new stacks are much longer (not a problem in practice thanks to CSS variables) but they cover all common browsing devices (including smartphones). I crafted the list from the recommended font stacks of the most popular CSS frameworks and the most popular websites for developers.
2023-07-19 12:01:23 +01:00
Kamil Tekiela 9e32ca8e9a Enable horizontal scroll bar for code blocks (#770) 2023-06-23 09:29:06 -05:00
Javier Eguiluz 44927b5cdc Improve magenta contrast to fix accessibility issues (#749) 2023-02-21 15:02:35 +00:00
Christoph M. Becker b7bccc4049 Properly handle whitespace in PHP examples
PhD no longer renders NBSPs, but regular spaces instead[1].  To retain
the desired indentation, we set the CSS propery `white-space:pre`.
However, we cannot do that for the `.phpcode` class directly, because
`highlight_string()` emits additional line breaks at the top and the
bottom of the examples, so we use a more specific selector to avoid
this "padding".

[1] <https://github.com/php/phd/commit/87f794bafe22631f9886adb37db0bdf0006da3dd>
2023-01-04 15:45:40 +01:00
Christoph M. Becker 35430003f4 Revert "Apply white-space:pre to .phpcode and div.classsynopsis"
This reverts commit 65fc7be9a6.
2023-01-03 15:19:44 +01:00
Christoph M. Becker 65fc7be9a6 Apply white-space:pre to .phpcode and div.classsynopsis
This is currently unnecessary, since PhD renders NBSPs instead of
regular space there, but if that changes, the layout needs to be
preserved.

Closes GH-744.
2023-01-03 13:12:50 +01:00
Steve Desmond b4a8b2640b Fix content layout on pages without sidebars for 768-979px viewport widths
Fixes GH-500.
Closes GH-501.
2022-10-17 14:07:31 +02:00
Levi Morrison 15d95ae47b Use CSS variables for some common colors (#689)
Aside from being able to tell what color it is or what purpose it
solves just by looking at the variable name, it helps provide a
foundation for more easily changing the theme in the future.

Hopefully, we'll have a light and dark theme one day.
2022-09-01 11:47:43 -06:00
Ayesh Karunaratne c1dce9083b Minor optimizations in CSS files to shed some weight (#612)
- Removes px suffix from 0px.
 - Combines CSS properties where they are immediately overridden in the same selector block, or can be combined without side effects.

 This saves about 50 bytes off the CSS scripts. it ain't much but it's honest work
2022-07-05 11:38:25 +01:00
Lucas Azevedo cfcf303e02 Improve homepage hero design
Co-authored-by: Kamil Tekiela <tekiela246@gmail.com>
Co-authored-by: Christoph M. Becker <cmbecker69@gmx.de>

Closes GH-459.
2022-06-13 16:07:27 +02:00
Ruslan 78a91db65b JS-13812 Develop markup for PHP 8 announcement on php.net 2020-11-25 20:28:13 +00:00
Markus Staab 6c8c2aa18c enable css-native smooth scrolling
remove javascript scroll magic

add a top-margin to all elements which get referenced by anchor-urls, so they are not covered by the fixed header
2020-08-25 16:38:31 +01:00
Peter Kokot 35e766d749 Fix permissions
Having synced file permissions in Git repositories is a reccurring
issue. Git can track files as executables (0755) or not (0644). Usually,
all files except the executable ones such as command line scripts or
binary executables, should be set to 0644.

This patch syncs permissions in the Git repository.
2018-10-25 02:22:08 +02:00
Jefrey Sobreira Santos d26b9a7148 vertically center search box 2018-10-17 11:12:33 +02:00
Peter Kokot e235f79473 Trim trailing whitespace
This patch cleans all redundant trailing whitespace across the
repository except for the icalendar files.
2018-10-17 10:51:08 +02:00
Peter Cowburn f226403f1d logo page improvements
Put back chunks of the old logo page that I'm nostalgic for.
Use print_image() function for rendering img tags as before.
Remove some now-unused CSS.
2018-03-14 23:53:20 +00:00
Peter Cowburn 5cd2f7b506 Merge branch 'pull-request/106' 2018-03-14 23:02:54 +00:00
Levi Morrison 418a39160d Fixes morrisonlevi/web-php#7 2016-11-10 11:09:08 -07:00
Levi Morrison 087370c3e0 Revert "Fixes morrisonlevi/web-php#1"
This reverts commit 0fd69e90a8.
2016-11-10 11:07:40 -07:00
Levi Morrison 0fd69e90a8 Fixes morrisonlevi/web-php#1 2016-11-10 11:05:10 -07:00
Wes 064f21a712 Fix page-tools hiding title on small devices 2016-07-16 00:01:09 +02:00
Webysther Nunes 0728162200 Removed whitespace 2016-06-02 19:57:35 -03:00
Webysther Nunes cd2613b5f0 Removed whitespace 2016-06-02 19:56:45 -03:00
Webysther Nunes 36b776453e Remove whitespace 2016-06-02 19:54:21 -03:00
Webysther Nunes a1c6585555 Correction for big screen 2016-06-02 17:59:17 -03:00
Webysther Nunes 431540b7ff Using grid to images; Better messages 2016-06-02 17:57:28 -03:00
Nathaniel McHugh 22c86e7b82 Add sha256 hashes to the download page. Should really remove md5 ones too but some people may still use them. 2015-04-17 14:07:29 +01:00
Hannes Magnusson 282981dd02 Style literallayouts a little better
See http://php.net/manual/en/language.operators.bitwise.php for exmaple
2015-04-09 12:03:20 -07:00
Peter Cowburn 2d15c50b8d add borders back to fieldsynopsis with better selector 2015-03-19 09:03:12 +00:00
Hannes Magnusson cc342a1f42 Remove these weird borders and margins from class constants 2015-02-03 14:21:17 -08:00
Adam Harvey c75362f02c Mark up field synopses like method synopses.
The right fix is probably to apply the dc-description class in PhD, but this at
least gets us the right formatting for now.

Fixes bug #68699 (Styling on OO/procedural fields is poor).
2014-12-30 12:05:31 -08:00
Sobak 0fe73752d8 Code examples being parts of FAQ questions should not be bolded
Example: http://php.net/manual/en/faq.using.php#faq.using.wrong-order
2014-12-27 17:10:53 +01:00
Levi Morrison 18e415e4c5 Correct font weight usage.
Remove Fira Sans SemiBold from fira.css, since after these corrections
it is no longer in use. This is one less thing to download, and saves
80KB over the wire.
2014-11-13 14:00:08 -07:00
Levi Morrison 37e5b25878 Adjust #breadcrumbs structure.
Also fix minor issue with #layout.
2014-11-12 11:42:02 -07:00
Levi Morrison 7b010a9321 Properly fix bug 68206
The issue itself and the issue with the previous fix have ben fixed.
I cannot identify other issues this may have caused; time will tell.
2014-10-27 11:31:18 -06:00
Adam Harvey f341179f16 Revert "Remove position: relative from the page tools, as suggested by romchik."
This reverts commit 49f29e4073.
2014-10-27 10:21:59 -07:00