style: настроил дизайн VK комментариев под тёмную тему

This commit is contained in:
Astronit 2026-02-20 12:40:05 +00:00
parent dacf5e6e60
commit fb49a0f38f
1 changed files with 18 additions and 3 deletions

View File

@ -2,11 +2,26 @@
<div id="vk_comments"></div> <div id="vk_comments"></div>
<script type="text/javascript" src="https://vk.com/js/api/openapi.js?169"></script> <script type="text/javascript" src="https://vk.com/js/api/openapi.js?169"></script>
<script type="text/javascript"> <script type="text/javascript">
VK.init({apiId: 54459311, onlyWidgets: true}); VK.init({apiId: YOUR_API_ID, onlyWidgets: true});
VK.Widgets.Comments("vk_comments", { VK.Widgets.Comments("vk_comments", {
limit: 10, limit: 10,
attach: "*", attach: "*",
autoPublish: 0, autoPublish: 0,
pageUrl: "{{ .Permalink }}" pageUrl: "{{ .Permalink }}",
width: "auto",
height: 400
}); });
</script> </script>
<style>
#vk_comments {
margin-top: 2rem;
padding-top: 2rem;
border-top: 1px solid rgba(255, 255, 255, 0.1);
}
/* Адаптация под тёмную тему */
#vk_comments iframe {
border-radius: 8px;
}
</style>