TextToolTip.gif

Text Tool Tip

Add a pop-up description box when a visitor hovers over a linked word or sentence. Below you will find a super-simple tutorial that will guide you through the installation and setup of this plugin.

 

 

Step 1: Insert the CSS

Insert the following code into your Squarespace site's Custom CSS editor or the Individual Page Header CSS injection (more info below) - the values in bold can be changed to suit your branding and site design. 

Where colour values are added, you can use either of the following:

  • Valid colour name e.g. 'red' or 'yellow'
  • Hex value e.g. #FECB2F
  • RGB(a) value e.g. rgb (255,255,255) or rgba (255,255,255,0.8)  - optional opacity value '0.8'
  • HSL(s) value e.g. hsl (0, 0%, 20%) or hsla (0, 0%, 20%, 0.8) optional opacity value '0.8'

If you need help finding colours and building colour palettes - coolors.io is an awesome resource!
 

Where 'border' values are added, you can use either: 'dotted', 'dashed', 'solid' or 'double'. 

Copy & paste this code:

/* TEXT TOOL TIP CSS */

.sqs-block-markdown  span{
  border-bottom: dotted 1px #FECB2F;
  cursor: help;
}
.sqs-block-markdown span ttt{
  position: absolute;
  max-width: 200px;
  background-color: #000000;
  margin-left: 10px;
  padding: 15px 15px;
  color: #FFFFFF;
  border-radius: 3px;
  border: solid 1px #FECB2F;
  pointer-events: none;
  opacity: 0;
  -webkit-transition: all .3s ease-in-out !important;
  -moz-transition: all .3s ease-in-out !important;
  -o-transition: all .3s ease-in-out !important;
  transition: all .3s ease-in-out !important;
}
.sqs-block-markdown  span:hover ttt{
  opacity: 1 !important
}

@media all and (max-width: 1025px){
  .sqs-block-markdown span ttt{
    position: fixed !important;
    width: 100vw !important;
    height: auto !important;
    bottom: 0px !important;
    left: 0px !important;
    border-radius: 0px !important;
    max-width: none !important;
    margin: 0px;
  }
}
 

Finding your Custom CSS editor:

 

Individual Page Header CSS injection

 

 

Step 2: Add a Markdown Block

Insert a Markdown Block and insert the following code where you want the Text Tool Tip(s) to appear. 

The text after <span> and before <ttt> will be the trigger text link and the text inside <ttt> and </ttt> will be the text that displays on hover.

Here's how to set up the Text tool Tip itself:
 

<span>TRIGGER TEXT GOES HERE<ttt>DESCRIPTION TEXT GOES HERE</ttt></span>


Here's an example of a Markdown block with the Text Tool Tip included within a body of text content:

 
 

⚡️ Apply, Save & Refresh! ⚡️

 

Need some help?

If you need help installing your plugin or you find that the code provided is not working - please feel free to contact us by clicking the link below.