This commit is contained in:
parent
cba2e5a1c6
commit
f02f6c01b7
@ -1,4 +1,5 @@
|
||||
import { QuartzComponent, QuartzComponentConstructor, QuartzComponentProps } from "./types"
|
||||
// If `script` is required but causes type issues, consider fixing the type instead of ignoring.
|
||||
// @ts-ignore
|
||||
import script from "./scripts/_socialshare.inline"
|
||||
import style from "./styles/_socialshare.scss.scss"
|
||||
@ -7,71 +8,64 @@ const SocialShare: QuartzComponent = ({ displayClass, fileData }: QuartzComponen
|
||||
return (
|
||||
<div className="post-share">
|
||||
<div className="share-link">
|
||||
<a className="share-icon share-telegram"
|
||||
href="javascript:void(0);"
|
||||
<a
|
||||
className="share-icon share-telegram"
|
||||
href="#"
|
||||
onClick={(e) => e.preventDefault()}
|
||||
title="Поделиться в Telegram"
|
||||
data-sharer="telegram"
|
||||
data-url="{{url absolute=" true"}}"
|
||||
data-url={`{{url absolute=true}}`}
|
||||
data-title="{{title}}"
|
||||
data-caption="{{custom_excerpt}}">
|
||||
data-caption="{{custom_excerpt}}"
|
||||
>
|
||||
<span className="svg-social-icon icon-telegram"></span>
|
||||
</a>
|
||||
</div>
|
||||
<div className="share-link">
|
||||
<a className="share-icon share-twitter"
|
||||
href="javascript:void(0);"
|
||||
<a
|
||||
className="share-icon share-twitter"
|
||||
href="#"
|
||||
onClick={(e) => e.preventDefault()}
|
||||
title="Поделиться в Twitter"
|
||||
data-sharer="twitter"
|
||||
data-url="{{url absolute=" true"}}"
|
||||
data-title="{{title}}">
|
||||
data-url={`{{url absolute=true}}`}
|
||||
data-title="{{title}}"
|
||||
>
|
||||
<span className="svg-social-icon icon-twitter"></span>
|
||||
</a>
|
||||
</div>
|
||||
<!-- <div class="share-link">-->
|
||||
<!-- <a class="share-icon share-whatsapp"-->
|
||||
<!-- href="javascript:void(0);"-->
|
||||
<!-- title="Поделиться в WhatsApp"-->
|
||||
<!-- data-sharer="whatsapp"-->
|
||||
<!-- data-url="{{url absolute="true"}}"-->
|
||||
<!-- data-title="{{title}}"-->
|
||||
<!-- data-web="">-->
|
||||
<!-- <span class="svg-social-icon icon-whatsapp"></span>-->
|
||||
<!-- </a>-->
|
||||
<!-- </div>-->
|
||||
<!-- <div class="share-link">-->
|
||||
<!-- <a class="share-icon share-vk"-->
|
||||
<!-- href="javascript:void(0);"-->
|
||||
<!-- title="Поделиться в VK"-->
|
||||
<!-- data-sharer="vk"-->
|
||||
<!-- data-url="{{url absolute="true"}}"-->
|
||||
<!-- data-title="{{title}}"-->
|
||||
<!-- data-caption="{{custom_excerpt}}">-->
|
||||
<!-- <span class="svg-social-icon icon-vk"></span>-->
|
||||
<!-- </a>-->
|
||||
<!-- </div>-->
|
||||
{/* Uncomment and fix other sections as needed */}
|
||||
<div className="share-link">
|
||||
<a className="share-icon share-pocket"
|
||||
href="javascript:void(0);"
|
||||
<a
|
||||
className="share-icon share-pocket"
|
||||
href="#"
|
||||
onClick={(e) => e.preventDefault()}
|
||||
title="Поделиться в Pocket"
|
||||
data-title="{{title}}"
|
||||
data-sharer="pocket"
|
||||
data-url="{{url absolute=" true"}}">
|
||||
data-url={`{{url absolute=true}}`}
|
||||
>
|
||||
<span className="svg-social-icon icon-pocket"></span>
|
||||
</a>
|
||||
</div>
|
||||
<div className="share-link">
|
||||
<a className="share-icon share-skype"
|
||||
href="javascript:void(0);"
|
||||
<a
|
||||
className="share-icon share-skype"
|
||||
href="#"
|
||||
onClick={(e) => e.preventDefault()}
|
||||
title="Поделиться в Skype"
|
||||
data-sharer="skype"
|
||||
data-url="{{url absolute=" true"}}"
|
||||
data-title="{{title}}">
|
||||
data-url={`{{url absolute=true}}`}
|
||||
data-title="{{title}}"
|
||||
>
|
||||
<span className="svg-social-icon icon-skype"></span>
|
||||
</a>
|
||||
</div>
|
||||
</div>
|
||||
)
|
||||
}
|
||||
RandomPageButton.css = style
|
||||
RandomPageButton.afterDOMLoaded = script
|
||||
export default (() => RandomPageButton) satisfies QuartzComponentConstructor
|
||||
|
||||
SocialShare.css = style;
|
||||
SocialShare.afterDOMLoaded = script;
|
||||
|
||||
export default (() => SocialShare) satisfies QuartzComponentConstructor;
|
||||
|
Loading…
Reference in New Issue
Block a user