mirror of
https://github.com/Kingsrook/qqq.git
synced 2025-07-21 14:38:43 +00:00
Compare commits
6 Commits
snapshot-f
...
version-0.
Author | SHA1 | Date | |
---|---|---|---|
6702c06ed0 | |||
9dfbd839c8 | |||
724d5779cc | |||
1fef376e65 | |||
47e27d5ffc | |||
494ec00b84 |
2
pom.xml
2
pom.xml
@ -46,7 +46,7 @@
|
|||||||
</modules>
|
</modules>
|
||||||
|
|
||||||
<properties>
|
<properties>
|
||||||
<revision>0.21.0-SNAPSHOT</revision>
|
<revision>0.21.0</revision>
|
||||||
|
|
||||||
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
|
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
|
||||||
<project.reporting.outputEncoding>UTF-8</project.reporting.outputEncoding>
|
<project.reporting.outputEncoding>UTF-8</project.reporting.outputEncoding>
|
||||||
|
@ -40,9 +40,10 @@ public class CompositeWidgetData extends AbstractBlockWidgetData<CompositeWidget
|
|||||||
{
|
{
|
||||||
private List<AbstractBlockWidgetData<?, ?, ?, ?>> blocks = new ArrayList<>();
|
private List<AbstractBlockWidgetData<?, ?, ?, ?>> blocks = new ArrayList<>();
|
||||||
|
|
||||||
private Map<String, Serializable> styleOverrides = new HashMap<>();
|
private Layout layout;
|
||||||
|
private Map<String, Serializable> styleOverrides = new HashMap<>();
|
||||||
private Layout layout;
|
private String overlayHtml;
|
||||||
|
private Map<String, Serializable> overlayStyleOverrides = new HashMap<>();
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
@ -218,4 +219,91 @@ public class CompositeWidgetData extends AbstractBlockWidgetData<CompositeWidget
|
|||||||
return (this);
|
return (this);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/*******************************************************************************
|
||||||
|
** Getter for overlayHtml
|
||||||
|
*******************************************************************************/
|
||||||
|
public String getOverlayHtml()
|
||||||
|
{
|
||||||
|
return (this.overlayHtml);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/*******************************************************************************
|
||||||
|
** Setter for overlayHtml
|
||||||
|
*******************************************************************************/
|
||||||
|
public void setOverlayHtml(String overlayHtml)
|
||||||
|
{
|
||||||
|
this.overlayHtml = overlayHtml;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/*******************************************************************************
|
||||||
|
** Fluent setter for overlayHtml
|
||||||
|
*******************************************************************************/
|
||||||
|
public CompositeWidgetData withOverlayHtml(String overlayHtml)
|
||||||
|
{
|
||||||
|
this.overlayHtml = overlayHtml;
|
||||||
|
return (this);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/*******************************************************************************
|
||||||
|
** Getter for overlayStyleOverrides
|
||||||
|
*******************************************************************************/
|
||||||
|
public Map<String, Serializable> getOverlayStyleOverrides()
|
||||||
|
{
|
||||||
|
return (this.overlayStyleOverrides);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/*******************************************************************************
|
||||||
|
** Setter for overlayStyleOverrides
|
||||||
|
*******************************************************************************/
|
||||||
|
public void setOverlayStyleOverrides(Map<String, Serializable> overlayStyleOverrides)
|
||||||
|
{
|
||||||
|
this.overlayStyleOverrides = overlayStyleOverrides;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/*******************************************************************************
|
||||||
|
** Fluent setter for overlayStyleOverrides
|
||||||
|
*******************************************************************************/
|
||||||
|
public CompositeWidgetData withOverlayStyleOverrides(Map<String, Serializable> overlayStyleOverrides)
|
||||||
|
{
|
||||||
|
this.overlayStyleOverrides = overlayStyleOverrides;
|
||||||
|
return (this);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/*******************************************************************************
|
||||||
|
**
|
||||||
|
*******************************************************************************/
|
||||||
|
public CompositeWidgetData withOverlayStyleOverride(String key, Serializable value)
|
||||||
|
{
|
||||||
|
addOverlayStyleOverride(key, value);
|
||||||
|
return (this);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/*******************************************************************************
|
||||||
|
**
|
||||||
|
*******************************************************************************/
|
||||||
|
public void addOverlayStyleOverride(String key, Serializable value)
|
||||||
|
{
|
||||||
|
if(this.overlayStyleOverrides == null)
|
||||||
|
{
|
||||||
|
this.overlayStyleOverrides = new HashMap<>();
|
||||||
|
}
|
||||||
|
this.overlayStyleOverrides.put(key, value);
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
@ -24,6 +24,7 @@ package com.kingsrook.qqq.backend.core.model.dashboard.widgets.blocks;
|
|||||||
|
|
||||||
import java.util.HashMap;
|
import java.util.HashMap;
|
||||||
import java.util.Map;
|
import java.util.Map;
|
||||||
|
import com.kingsrook.qqq.backend.core.model.dashboard.widgets.CompositeWidgetData;
|
||||||
import com.kingsrook.qqq.backend.core.model.dashboard.widgets.QWidgetData;
|
import com.kingsrook.qqq.backend.core.model.dashboard.widgets.QWidgetData;
|
||||||
|
|
||||||
|
|
||||||
@ -203,6 +204,19 @@ public abstract class AbstractBlockWidgetData<
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/*******************************************************************************
|
||||||
|
** Fluent setter for tooltip
|
||||||
|
**
|
||||||
|
*******************************************************************************/
|
||||||
|
@SuppressWarnings("unchecked")
|
||||||
|
public T withTooltip(CompositeWidgetData data)
|
||||||
|
{
|
||||||
|
this.tooltip = new BlockTooltip(data);
|
||||||
|
return (T) (this);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
/*******************************************************************************
|
/*******************************************************************************
|
||||||
**
|
**
|
||||||
*******************************************************************************/
|
*******************************************************************************/
|
||||||
@ -398,6 +412,7 @@ public abstract class AbstractBlockWidgetData<
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
/*******************************************************************************
|
/*******************************************************************************
|
||||||
** Getter for blockId
|
** Getter for blockId
|
||||||
*******************************************************************************/
|
*******************************************************************************/
|
||||||
@ -428,5 +443,4 @@ public abstract class AbstractBlockWidgetData<
|
|||||||
return (T) this;
|
return (T) this;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
@ -22,14 +22,18 @@
|
|||||||
package com.kingsrook.qqq.backend.core.model.dashboard.widgets.blocks;
|
package com.kingsrook.qqq.backend.core.model.dashboard.widgets.blocks;
|
||||||
|
|
||||||
|
|
||||||
|
import com.kingsrook.qqq.backend.core.model.dashboard.widgets.CompositeWidgetData;
|
||||||
|
|
||||||
|
|
||||||
/*******************************************************************************
|
/*******************************************************************************
|
||||||
** A tooltip used within a (widget) block.
|
** A tooltip used within a (widget) block.
|
||||||
**
|
**
|
||||||
*******************************************************************************/
|
*******************************************************************************/
|
||||||
public class BlockTooltip
|
public class BlockTooltip
|
||||||
{
|
{
|
||||||
private String title;
|
private CompositeWidgetData blockData;
|
||||||
private Placement placement = Placement.BOTTOM;
|
private String title;
|
||||||
|
private Placement placement = Placement.BOTTOM;
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
@ -62,6 +66,17 @@ public class BlockTooltip
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/*******************************************************************************
|
||||||
|
** Constructor
|
||||||
|
**
|
||||||
|
*******************************************************************************/
|
||||||
|
public BlockTooltip(CompositeWidgetData blockData)
|
||||||
|
{
|
||||||
|
this.blockData = blockData;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
/*******************************************************************************
|
/*******************************************************************************
|
||||||
** Getter for title
|
** Getter for title
|
||||||
*******************************************************************************/
|
*******************************************************************************/
|
||||||
@ -122,4 +137,35 @@ public class BlockTooltip
|
|||||||
return (this);
|
return (this);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/*******************************************************************************
|
||||||
|
** Getter for blockData
|
||||||
|
*******************************************************************************/
|
||||||
|
public CompositeWidgetData getBlockData()
|
||||||
|
{
|
||||||
|
return (this.blockData);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/*******************************************************************************
|
||||||
|
** Setter for blockData
|
||||||
|
*******************************************************************************/
|
||||||
|
public void setBlockData(CompositeWidgetData blockData)
|
||||||
|
{
|
||||||
|
this.blockData = blockData;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/*******************************************************************************
|
||||||
|
** Fluent setter for blockData
|
||||||
|
*******************************************************************************/
|
||||||
|
public BlockTooltip withBlockData(CompositeWidgetData blockData)
|
||||||
|
{
|
||||||
|
this.blockData = blockData;
|
||||||
|
return (this);
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user