- From: Mahdi Hosseinzadeh via GitHub <sysbot+gh@w3.org>
- Date: Sat, 06 Nov 2021 09:23:48 +0000
- To: public-svg-issues@w3.org
mahozad has just created a new issue for https://github.com/w3c/svgwg: == Add specification for defining favicon for SVG document == Is it possible to specify a favicon for the SVG image itself so, when opened in a browser, its favicon is displayed on browser tab? Just like a regular HTML document containing a favicon like so: ```html <link rel="icon" href="favicon.ico" type="image/x-icon"> ``` Looking at [SVG v2 specifications], it seems that this issue may relate to the following sections: - [HTML metadata elements] - [The effects of HTML `link` element] - [The `defs` element] - [The `foreignObject` element] - [The `unknown` element] - [Linking in SVG]. [This stackoverflow post] asks about this. It says that we can currently add the following (preferably to `<defs>` element) in the SVG document: ```xml <link xmlns="http://www.w3.org/1999/xhtml" rel="shortcut icon" href="favicon.ico" /> ``` And it seems to work (at least in Chrome and Firefox). Open the following SVG image (which contains a favicon) in a new tab to see the favicon; may not work in mobile browsers: <img width="224px" align="center" src="https://raw.githubusercontent.com/mahozad/vectors/1a78ea214e7587c8c04482a2afc8830574d8f5eb/mazzeh-logo/logo-final-nodes-on-grids-updated-with-shadow.svg" /> Can the specification add/clarify this feature officially? [SVG v2 specifications]: https://svgwg.org/svg-next/ [HTML metadata elements]: https://svgwg.org/svg-next/struct.html#HTMLMetadataElements [The effects of HTML `link` element]: https://svgwg.org/svg-next/styling.html#LinkElement [The `foreignObject` element]: https://svgwg.org/svg-next/embedded.html#ForeignObjectElement [The `defs` element]: https://svgwg.org/svg-next/struct.html#Head [The `unknown` element]: https://svgwg.org/svg-next/struct.html#UnknownElement [Linking in SVG]: https://svgwg.org/svg-next/linking.html [This stackoverflow post]: https://stackoverflow.com/q/13324547/8583692 Please view or discuss this issue at https://github.com/w3c/svgwg/issues/869 using your GitHub account -- Sent via github-notify-ml as configured in https://github.com/w3c/github-notify-ml-config
Received on Saturday, 6 November 2021 09:23:49 UTC