1
0
mirror of synced 2025-12-30 03:01:36 -05:00
Commit Graph

326 Commits

Author SHA1 Message Date
Evan Bonsignori
b1a36fb7ff Revert "set max-age=0 when you want no cache (#31657)"
This reverts commit 5dfca10bba.
2022-10-12 13:10:34 -07:00
Peter Bengtsson
5dfca10bba set max-age=0 when you want no cache (#31657) 2022-10-12 19:54:28 +00:00
Sarah Schneider
6c51c13392 Support deep links on homepage (#31172)
Co-authored-by: Peter Bengtsson <peterbe@github.com>
2022-10-12 12:58:46 +00:00
github-openapi-bot
757066487d Update OpenAPI Descriptions (#30924)
Co-authored-by: github-openapi-bot <github-openapi-bot@users.noreply.github.com>
Co-authored-by: Rachael Sewell <rachmari@github.com>
Co-authored-by: Grace Park <gracepark@github.com>
Co-authored-by: Grace Park <gracepark@Graces-MacBook-Pro-2.local>
Co-authored-by: Hector Alfaro <hectorsector@github.com>
Co-authored-by: Ashwin Jeyaseelan <8gitbrix@github.com>
Co-authored-by: hubwriter <hubwriter@github.com>
Co-authored-by: Sarita Iyer <66540150+saritai@users.noreply.github.com>
2022-09-19 10:28:23 -07:00
Peter Bengtsson
90b754fe3c Test JSON API without enabling dedicated search results page (#30542) 2022-09-06 17:05:22 +00:00
Kevin Heis
303d5190db Create a translations test suite (#30000)
* Scaffold files for migration

* Move user-agent into unit suite

* Nothing to move from browser suite

* Migrate tests to translations/content

* Migrate existing translation test to meta

* No graphql tests to migrate

* Migrate lint-translation-reporter

* Migrate lint-translation-reporter

* Remove languages-schema, unused

* Restore languages-schema

* Restore languages-schema

* Migrate rendering

* Migrate routing

* Migrate most of unit

* Remove dead files, comment out tests that aren't expected to work yet

* Migrate from get-redirect

* Migrate page and pages

* Migrate linting code

* Fix lint issues

* Found a few more

* Run prettier

* Move crowdin-config test and helper

* Update crowdin-config.js

* Remove translation linting, crowdin config lint, reduce file count

* Remove test that's been skipped for a year

* Restore linting with note to remove later

* Update lint-translation-reporter.js

* Clean up rendering suite

* Update rendering.js

* Remove excessive describe blocks

* Redirect tests

* Clean up unit

* Remove test that's never called

* Don't compare early access

* Rename test suites

* Update "content" tests

* Update files.js

* Update search.js

* Update files.js

* Update files.js
2022-08-25 12:38:03 -07:00
Grace Park
df6b782b11 Update navlist for MiniTocs (#30167)
* update navlist

* fix tests

* update to component

* update platform

* update key

* fix platform tool picker issue

* add key

* remove unnecessary key

* fix test

* update styling

* fix indented test

* Update components/ui/MiniTocs/MiniTocs.tsx

Co-authored-by: Peter Bengtsson <peterbe@github.com>

* remove null

Co-authored-by: Peter Bengtsson <peterbe@github.com>
2022-08-25 09:33:08 -07:00
Sarah Edwards
d2a2113c11 REST new user guidance (#29642) 2022-08-23 19:31:01 +00:00
Peter Bengtsson
8765c628ff dedicated search results page (redux) (#29902)
* dedicated search results page (redux)

* Update SearchResults.tsx

* adding pagination

* fix pagination

* say something on NoQuery

* better Flash

* tidying link

* small fixes for results

* debug info

* l18n the meta info

* inDebugMode

* basic jest rendering of the skeleton page

* basic jest rendering test

* fix content tests

* better document title

* fix tests

* quote query in page title

* use home page sidebar

* something when nothing is found

* parseInt no longer needs the 10

* fix linting tests

* fix test

* prettier

* Update pages/search.tsx

Co-authored-by: Rachael Sewell <rachmari@github.com>

Co-authored-by: Kevin Heis <heiskr@users.noreply.github.com>
Co-authored-by: Rachael Sewell <rachmari@github.com>
2022-08-19 13:36:55 +00:00
Peter Bengtsson
d38b8351a8 Revert "Update to NavList for minitocs" (#30051)
Revert "Update to NavList for minitocs (#29885)"

This reverts commit b5ea7bbcc5.
2022-08-18 09:44:23 -04:00
Robert Sese
59d1f3ea9a Update translation header tests since contact link has been removed (#29978)
Contact link has been removed
2022-08-16 11:29:01 +00:00
Kevin Heis
c8ae2081b7 Remove feature flags (#29968) 2022-08-16 11:23:02 +00:00
Kevin Heis
688a274f1f Remove CSRF check (#29910)
* Use color_mode for gating "sign up" button

* Remove csrf check

* Add `res.removeHeader('set-cookie')` to cache-control

* Update static-assets.js

* Remove package

* Remove tough-cookie

* Update cache-control.js

* Update cache-control.js

* Update cache-control.js
2022-08-15 19:28:42 +00:00
Hector Alfaro
54d996f186 Localization: Clean up Microsoft workflow (#29675)
* remove comments that no longer apply

* remove unused matrix variables

* remove CrowdIn-specific step of resetting broken files

* udpate link to Microsoft-specific log

* bring back reset script still in use

* add acceptable ja translation of TOS to rendering test

* add ability to remove files that have been translated but don't exist (wip)

* document what `languageFiles()` returns

* fix path issues for removed translations

* cleaner script execution

* add removed files to CSV report

* add workflow link to PR body for better troubleshooting

* catch missing regex for reporting file removals

* fix capturing groups in regex for csv reporting

* fix link to CSV file for PR

* fix formatting for PR

* pass in branch name from workflow

* put back helper scripts, make msft-specific copies
2022-08-15 17:17:25 +00:00
Grace Park
b5ea7bbcc5 Update to NavList for minitocs (#29885)
* update to NavList for minitocs

* fix minitoc tests
2022-08-11 18:40:02 -07:00
Peter Bengtsson
a1e3866fa5 don't get available languages from session (#29715)
* don't get available languages from session

* update useSession

* one more fix
2022-08-08 11:13:27 -04:00
Kevin Heis
56aa9ea094 Move use session to its own hook file (#29641)
* Move use session to its own hook file

* Trying useSWR

* Try one hour html cache

* blah blah lint

* Update to include loading state

* Update components/hooks/useSession.ts

Co-authored-by: Peter Bengtsson <peterbe@github.com>

Co-authored-by: Peter Bengtsson <peterbe@github.com>
2022-08-05 14:47:10 +00:00
Kevin Heis
bb1f30a39b Update HTML cache control to 10 minutes (#29586)
* Update HTML cache control to 10 minutes

* A little clean up

* Remove quick-lru
2022-08-03 20:39:54 +00:00
Kevin Heis
bee3b5c9f3 Enable up to one minute of HTML caching (#29572)
* Enable up to one minute of HTML caching

* Skip a test that isn't the level of cache control we now want
2022-08-03 16:26:53 +00:00
Kevin Heis
f8d2395960 Remove theme from HTML (#29560)
* Remove theme from HTML

* update for linting error

* Fix for overriding default color modes

Co-authored-by: Grace Park <lugraciecy@gmail.com>
Co-authored-by: Grace Park <gracepark@github.com>
2022-08-02 17:06:54 -07:00
Kevin Heis
a16aeac936 Prepare render-page for re-enabling HTML caching (#29473)
* Prepare render-page for re-enabling HTML caching

* Prepare render-page for re-enabling HTML caching

* Prepare render-page for re-enabling HTML caching

* Update healthz.js

* Pre calculate cache control directives

* Update render-page.js
2022-07-29 19:49:36 +00:00
Octomerger Bot
ff2f9a0b14 Merge branch 'main' into repo-sync 2022-07-28 15:00:31 -04:00
Kevin Heis
0886faddac Move language context to browser/session (#29433) 2022-07-28 18:50:46 +00:00
Nick McCurdy
f028bd7a21 Merge branch 'main' into fix-links-to-feedback-discussions 2022-07-27 17:57:13 -04:00
Nick McCurdy
d6a886b6d0 Rename github-community to community 2022-07-27 17:36:23 -04:00
Kevin Heis
f79e1d2cb7 Fetch CSRF token over XHR (browser-side) (#29337)
* Client side csrf token grab

* Update get-session.ts

* Update get-session.ts

* Update get-session.ts

* Remove test refs to meta tag

* Update get-session.ts

* Update get-session.ts

* Update get-session.ts

* Update get-session.ts

* Fix some type issues

* Simplify api

* Update components/lib/get-session.ts

Co-authored-by: Rachael Sewell <rachmari@github.com>

Co-authored-by: Rachael Sewell <rachmari@github.com>
2022-07-27 16:18:07 +00:00
Courtney Wilson
be95e8e56d Merge branch 'main' into fix-links-to-feedback-discussions 2022-07-26 15:56:10 -04:00
Kevin Heis
2182ff28f3 Next12 now supports ESM (#29295)
* Next12 now supports ESM

* No more michael jackson script extensions

* Fix test running

* Update jest-puppeteer.config.cjs

* Update package.json
2022-07-26 17:53:23 +00:00
Grace Park
798dd62609 Update page-data to parseAndRender childPage titles (#29265)
* start

* updating page-data

* fix test'

* remove unnecessary file check

* remove line

* line

* remove file check

* fix title -> shortTitle

Co-authored-by: docubot <67483024+docubot@users.noreply.github.com>
2022-07-22 11:32:30 -07:00
Kevin Heis
564e3a5e2a Move CSRF response back to XHR (Node.js prep) (#29179)
* Move CSRF response back to XHR

* Update events.js

* Pass through cookieJar

* Enable session route test

* Skip next x csrf test

* Add other fields to endpoint for future issues

* Remove client side parts

* Revert test skip

* Use nested router pattern

* ugh forgot a file

* Update naming

* Update tests/rendering/session.js

Co-authored-by: Peter Bengtsson <peterbe@github.com>

* Updating to use cache control

* Use req.langauge and req.userLanguage

Co-authored-by: Peter Bengtsson <peterbe@github.com>
2022-07-22 18:17:22 +00:00
Sarah Schneider
73cd3db0d1 Update tests/rendering/server.js
Co-authored-by: Peter Bengtsson <peterbe@github.com>
2022-07-22 12:09:33 -04:00
Sarah Schneider
79a8d03afc update test to reflect the latest rewrite-links functionality 2022-07-22 10:38:21 -04:00
Nick McCurdy
619aa2e9cd Merge branch 'main' of https://github.com/github/docs into fix-links-to-feedback-discussions 2022-07-19 06:22:27 -04:00
Peter Bengtsson
37d3bded04 simplify Table of Contents (#28833)
* simplify table-of-contents

* key

* fix rendering tests

* Not so much top margin

* Map topic ToC links are spans

* use p tag

* Back to span for the article title

* Update comment to match markup

* remove hack

* use h2 instead

* fix tests

* fix use of key

* use regular className instead

Co-authored-by: Robert Sese <734194+rsese@users.noreply.github.com>
2022-07-14 14:28:41 +00:00
Grace Park
822fe2926b Megabranch: Upgrade primer/react (#28458)
* upgrade primer/react

* upgrade

* using deprecated

* remove lib"

* Upgrade primer/react: Upgrade Label (#28502)

update Label to primer/react 35.2.2

* fix merge conflicts

* primer/react v35: update ActionList (#28467)

* Update to v35 ActionList for LearningTrack

* Update to v35 ActionList for ArticleList

* Update to v35 ActionList for ProductArticleList

* Update to v35 ActionList for TableOfContents

* Update to v35 ActionList for ProductCollapsibleSection

* Update to v35 ActionList for RestCollapsibleSection

* Update to v35 ActionList for SidebarHomepage

* Update to v35 ActionList for MiniTocs

* Update to v35 ActionList for Search

* Extra div for rendering test

* One less div for rendering test

* All the style updates for v35 ActionList

* Works without setting as an li which is already the default (didn't before for some reason)

* Use deprecated ItemInput for now

* Picker update for primer/react (#28485)

* update picker

* inline picker for mobile

* set width to auto

* Update components/ui/Picker/Picker.tsx

Co-authored-by: Kevin Heis <heiskr@users.noreply.github.com>

* update

* Update Picker.tsx

* update onselect

* checking language code

* move language cookie setting to language picker

Co-authored-by: Kevin Heis <heiskr@users.noreply.github.com>

* Resolve package merge conflicts

* fresh npm install

* Primer update UnderlineNav (#28582)

* update underlinenav for primer/react update

* update tests

* update switches test

* update one last label

* update header test"

* remove href in underlinenav

* update rendering tests

* update cursor

* primer/react v35: update DropDownMenu to ActionMenu (#28576)

* Update to v35 ActionMenu for ArticleCards

* Update to v35 ActionMenu for Search

* Set button to inline-block

* Put the props on the overlay

* Update test for ActionMenu markup

* update package

* update package lock

* primer/react v35: CodeLanguagePicker update from SelectMenu to ActionMenu (#28625)

* Use octicon for menu down arrow

* Update to v35 ActionMenu for CodeLanguagePicker

* update to SubNav

Co-authored-by: Grace Park <gracepark@github.com>

* update package-lock

Co-authored-by: Robert Sese <734194+rsese@users.noreply.github.com>
Co-authored-by: Kevin Heis <heiskr@users.noreply.github.com>
2022-07-11 11:51:18 -07:00
Nick McCurdy
a56fde7040 Fix links to feedback discussions 2022-06-30 01:26:59 -04:00
Nick McCurdy
0f8139c12d Update feedback repository URL 2022-06-30 00:40:34 -04:00
Peter Bengtsson
ee1f20f4fb jest 28.1.1 (#28797)
* got 28.1.1

* wip

* force upgrade nth-check

* legacyFakeTimers
2022-06-29 11:55:03 +00:00
Kevin Heis
f948c81038 Upgrade got (#28617)
* Upgrade got

* Update e2etest.js

* Skip following redirects on redirect tests

* Update deprecated-enterprise-versions.js
2022-06-21 16:23:51 +00:00
Matt Pollard
965e27ca3a Merge branch 'main' into copilot-ga-megabranch 2022-06-20 09:43:14 +02:00
Matt Pollard
8297c57ac3 Add article with conceptual overview of GitHub Enterprise Server (#28221) 2022-06-17 09:25:36 +00:00
Jules
14b008c99b Merge branch 'main' into copilot-ga-megabranch 2022-06-17 09:56:12 +02:00
Peter Bengtsson
a39614fdcf remove supertest dependency (#28572)
* remove supertest dependency

* remove bad test
2022-06-16 15:56:41 +00:00
Peter Bengtsson
d4692b208e put the full plan name in the page titles (#28450)
* put the full plan name in the page titles

* fix tests
2022-06-16 13:29:23 +00:00
Robert Sese
61a777f18d Update rendering tests to use different products 2022-06-08 12:05:45 -05:00
Robert Sese
fd521e25e4 Use repositories product for breadcrumbs tests 2022-06-08 11:18:18 -05:00
Matt Pollard
f117de3e4d Fix test 2022-06-08 14:47:20 +02:00
Matt Pollard
e2be0f253c Remove unnecessary tests 2022-06-08 14:44:12 +02:00
Peter Bengtsson
d014f36222 fix external redirects (#28063)
* fix external redirects

* oops

* feedbacked
2022-06-02 02:06:29 +00:00
Mike Surowiec
b4608a86d8 fix: remove usage of readFileAsync (#28053)
* fix: remove usage of readFileAsync

* fix: use same import style

* fix: update tests

Co-authored-by: Peter Bengtsson <mail@peterbe.com>
2022-06-01 14:49:30 +00:00