import{_ as k}from"./BButton.vue_vue_type_script_setup_true_lang-D5Eg7-Zv-DDRCX2AG.js";import{_ as d,d as l,h as u,o as r,c as i,w as s,a as n}from"./index-D02r7Zsc.js";import"./BSpinner.vue_vue_type_script_setup_true_lang-H1MzHypA-D8AXjJB0.js";import"./dom-DVb-f0ZG-Crdf0-mU.js";import"./useDefaults-DESCdb0p-CFLjYrdG.js";import"./useColorVariantClasses-ZDE19TZw-Cvu7SygP.js";import"./BLink.vue_vue_type_script_setup_true_lang-Ct47WhzE-DDPYis_D.js";import"./object-0ALvRU0O-3BORTTD-.js";import"./stringUtils-gJJ6T6UC-g5BZrMym.js";import"./index-C0p9vHHI-DoOEDIMw.js";const b={props:{element:{type:Object,required:!0}},methods:{addNoticeToBookmarks(){this.getModule("bookmarkbutton").changeBookmarkState(this.element.recordId)},checkBookmark(){return this.getModule("bookmarkbutton").checkBookmark(this.element.recordId)}},computed:{showBookmark:function(){return!this.getConfig().disabledElements.includes("bookmarkedrecords")},bookmarkState:function(){return!this.element.recordId||!this.get("bookmarks")?!1:this.get("bookmarks").includes(this.element.recordId)}}},c={key:0};function f(o,e,p,B,h,t){const a=k;return t.showBookmark?(r(),l("div",c,[t.bookmarkState?(r(),i(a,{key:0,size:"sm",variant:"transparent","aria-label":o.$t("ariaLabels.bookmarkButton.removeBookmark"),onClick:e[0]||(e[0]=m=>t.addNoticeToBookmarks())},{default:s(()=>[...e[2]||(e[2]=[n("i",{"aria-hidden":"true",class:"bi bi-heart-fill text-beautiful-red",style:{"font-size":"1.7rem"}},null,-1)])]),_:1},8,["aria-label"])):(r(),i(a,{key:1,size:"sm",variant:"transparent","aria-label":o.$t("ariaLabels.bookmarkButton.addBookmark"),onClick:e[1]||(e[1]=m=>t.addNoticeToBookmarks())},{default:s(()=>[...e[3]||(e[3]=[n("i",{"aria-hidden":"true",class:"bi bi-heart text-beautiful-red",style:{"font-size":"1.7rem"}},null,-1)])]),_:1},8,["aria-label"]))])):u("",!0)}const I=d(b,[["render",f]]);export{I as default};
