Disclaimer
// This source code is subject to the terms of the Mozilla Public License 2.0 at https://mozilla.org/MPL/2.0/
// © Mr_Nikoru

//@version=5
indicator("Disclaimer", overlay=true)

txt_disclaimer_line1 = input.string("This is not a signal service. It will be used for educational chart mark ups and explanations. Trading is done at your own risk.","Disclaimer text line 1")
txt_disclaimer_line2 = input.string("",title= "Disclaimer text line 2")
txt_disclaimer_line3 = input.string("",title= "Disclaimer text line 3")
pos_disclaimer = input.string(position.top_right, "Disclaimer Position", options = [position.top_left,position.top_center,position.top_right,position.middle_left,position.middle_center,position.middle_right,position.bottom_left,position.bottom_center,position.bottom_right])
box_color = input.color(color.gray,"Box Colour")
txt_color = input.color(color.black,"Text Colour")

var disclaimer = table.new(pos_disclaimer,columns = 1, rows = 4, bgcolor = box_color, border_width = 1)

table.cell(disclaimer,0,0,text = "Disclaimer",text_color = txt_color, text_halign = text.align_center)
table.cell(disclaimer,0,1,text = txt_disclaimer_line1,text_color = txt_color, text_halign = text.align_center)    

if txt_disclaimer_line2 != ""

    table.cell(disclaimer,0,2,text = txt_disclaimer_line2,text_color = txt_color, text_halign = text.align_center)

if txt_disclaimer_line3 != ""

    table.cell(disclaimer,0,3,text = txt_disclaimer_line3,text_color = txt_color, text_halign = text.align_center)    

