Merge pull request #43 from akamensky/master
Add option for button text color inlining
This commit is contained in:
		@ -367,7 +367,7 @@ func (dt *Default) HTMLTemplate() string {
 | 
				
			|||||||
                              <tr>
 | 
					                              <tr>
 | 
				
			||||||
                                <td align="center">
 | 
					                                <td align="center">
 | 
				
			||||||
                                  <div>
 | 
					                                  <div>
 | 
				
			||||||
                                    <a href="{{ $action.Button.Link }}" class="button" style="background-color: {{ $action.Button.Color }}" target="_blank">
 | 
					                                    <a href="{{ $action.Button.Link }}" class="button" style="background-color: {{ $action.Button.Color }}; color: {{ $action.Button.TextColor }};" target="_blank">
 | 
				
			||||||
                                      {{ $action.Button.Text }}
 | 
					                                      {{ $action.Button.Text }}
 | 
				
			||||||
                                    </a>
 | 
					                                    </a>
 | 
				
			||||||
                                  </div>
 | 
					                                  </div>
 | 
				
			||||||
 | 
				
			|||||||
							
								
								
									
										2
									
								
								flat.go
									
									
									
									
									
								
							
							
						
						
									
										2
									
								
								flat.go
									
									
									
									
									
								
							@ -367,7 +367,7 @@ func (dt *Flat) HTMLTemplate() string {
 | 
				
			|||||||
                              <tr>
 | 
					                              <tr>
 | 
				
			||||||
                                <td align="center">
 | 
					                                <td align="center">
 | 
				
			||||||
                                  <div>
 | 
					                                  <div>
 | 
				
			||||||
                                    <a href="{{ $action.Button.Link }}" class="button" style="background-color: {{ $action.Button.Color }}" target="_blank">
 | 
					                                    <a href="{{ $action.Button.Link }}" class="button" style="background-color: {{ $action.Button.Color }}; color: {{ $action.Button.TextColor }}" target="_blank">
 | 
				
			||||||
                                      {{ $action.Button.Text }}
 | 
					                                      {{ $action.Button.Text }}
 | 
				
			||||||
                                    </a>
 | 
					                                    </a>
 | 
				
			||||||
                                  </div>
 | 
					                                  </div>
 | 
				
			||||||
 | 
				
			|||||||
@ -104,9 +104,10 @@ type Action struct {
 | 
				
			|||||||
 | 
					
 | 
				
			||||||
// Button defines an action to launch
 | 
					// Button defines an action to launch
 | 
				
			||||||
type Button struct {
 | 
					type Button struct {
 | 
				
			||||||
	Color string
 | 
						Color     string
 | 
				
			||||||
	Text  string
 | 
						TextColor string
 | 
				
			||||||
	Link  string
 | 
						Text      string
 | 
				
			||||||
 | 
						Link      string
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
// Template is the struct given to Golang templating
 | 
					// Template is the struct given to Golang templating
 | 
				
			||||||
 | 
				
			|||||||
		Reference in New Issue
	
	Block a user