Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Allow to customize close tooltip text (sidebar panel) #712

Merged
merged 7 commits into from
Feb 11, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
20 changes: 12 additions & 8 deletions src/components/App.vue
Original file line number Diff line number Diff line change
Expand Up @@ -211,7 +211,7 @@
>
<div id="g3w-sidebarpanel-header-placeholder">
<div
style = "display: flex;"
style = "display: flex; margin-bottom: 5px;"
:style = "{ justifyContent: app.sidebar.title ? 'space-between' : 'flex-end' }"
>

Expand All @@ -235,15 +235,19 @@
<i :class = "$fa('arrow-left')" class = "fa-stack-1x panel-icon"></i>
</span>
<span
@click.stop = "closeAllPanels"
data-placement = "left"
data-toggle = "tooltip"
data-container = "body"
v-t-tooltip.create = "'close'"
class = "skin-tooltip-left g3w-span-button close-pane-button fa-stack"
@click.stop = "app.sidebar.btn_close && closeAllPanels()"
data-toggle = "tooltip"
data-container = "body"
v-t-tooltip:right.create = "app.sidebar.tooltip_close || 'close'"
:current-tooltip = "app.sidebar.tooltip_close || 'close'"
class = "skin-tooltip-left g3w-span-button close-pane-button fa-stack"
>
<i :class = "$fa('circle')" class = "fa-stack-1x panel-button"></i>
<i :class = "$fa('close')" class = "fa-stack-1x panel-icon"></i>
<i
:style = "{ opacity: app.sidebar.btn_close ? '1' : '0.7', cursor: app.sidebar.btn_close ? 'pointer' : 'not-allowed' }"
:class = "$fa('close')"
class = "fa-stack-1x panel-icon">
</i>
</span>
</div>

Expand Down
1 change: 0 additions & 1 deletion src/components/QueryBuilder.vue
Original file line number Diff line number Diff line change
Expand Up @@ -375,7 +375,6 @@ export default {

<style scoped>
#query_builder {
font-family: monospace;
margin-bottom: 0;
height: 100%;
display: flex;
Expand Down
8 changes: 6 additions & 2 deletions src/store/application.js
Original file line number Diff line number Diff line change
Expand Up @@ -103,7 +103,7 @@ const STATE = Vue.observable({
* @since v3.11.0
* true open, false hide - icons only
*/
open : true
open : true,
},

layout: {
Expand Down Expand Up @@ -160,7 +160,11 @@ const STATE = Vue.observable({
/** DOM element where insert the component/panel */
parent: null,
/** barstack state. It stores the panel array */
contentsdata: [], // Array<{ content, options }>
contentsdata: [], // Array<{ content, options }>
/** @since 3.11.3 - whether to enable close button */
btn_close: true,
/** @since 3.11.3 - custom tooltip for close button */
tooltip_close: 'close',
},

contentsdata: [],
Expand Down