mirror of
https://github.com/BookStackApp/BookStack.git
synced 2025-08-06 12:02:45 +03:00
PWA Manifest: Tweaks during review of PR #4430
- Updated to go through HomeController with the builder as a helper class. - Extracted some reapeated items into variables in manifest. - Updated background color to match those used by BookStack. - Removed reference of icon.ico since its not intended to be used. - Added tests to cover functionality. Review of #4430
This commit is contained in:
@@ -140,4 +140,12 @@ class HomeController extends Controller
|
||||
$exists = $favicons->restoreOriginalIfNotExists();
|
||||
return response()->file($exists ? $favicons->getPath() : $favicons->getOriginalPath());
|
||||
}
|
||||
|
||||
/**
|
||||
* Serve a PWA application manifest.
|
||||
*/
|
||||
public function pwaManifest(PwaManifestBuilder $manifestBuilder)
|
||||
{
|
||||
return response()->json($manifestBuilder->build());
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user