Cart Buy Licenses Contact Support Login/Register
v 1.8.6
v 1.8.6
Overview Examples Docs Source Download

Brand your survey with your logo

Edit in CodeSandbox
import Vue from "vue"; import * as Survey from "survey-vue"; import "survey-vue/survey.css"; import "./index.css"; Survey.StylesManager.applyTheme("orange"); var json = { "title": "Survey Title&Logo demo", "description": "Please take look at the survey title and logo. Test the settings on the right panel ->", "logo": "https://surveyjs.io/favicon.ico", "logoWidth": 60, "logoHeight": 60, "questions": [ { "name": "name", "type": "text", "title": "Please enter your name:", "placeHolder": "Jon Snow", "isRequired": true }, { "name": "birthdate", "type": "text", "inputType": "date", "title": "Your birthdate:", "isRequired": true }, { "name": "color", "type": "text", "inputType": "color", "title": "Your favorite color:" }, { "name": "email", "type": "text", "inputType": "email", "title": "Your e-mail:", "placeHolder": "jon.snow@nightwatch.org", "isRequired": true, "validators": [ { "type": "email" } ] } ] }; let survey = new Survey.Model(json); survey.onComplete.add(function(result) { document.querySelector('#surveyResult').textContent = "Result JSON:\n" + JSON.stringify(result.data, null, 3); }); var app = new Vue({ el: '#surveyElement', data: { survey: survey } }); <div id="surveyElement" style="display:inline-block;width:100%;"> <survey :survey='survey' /> </div> <div id="surveyResult"></div>

Add your logo to the survey title.


                        
        
            Survey.StylesManager.applyTheme("orange");
        


            
                var json = {
  "title": "Survey Title&Logo demo",
  "description": "Please take look at the survey title and logo. Test the settings on the right panel ->",
  "logo": "https://surveyjs.io/favicon.ico",
  "logoWidth": 60,
  "logoHeight": 60,
  "questions": [
    {
      "name": "name",
      "type": "text",
      "title": "Please enter your name:",
      "placeHolder": "Jon Snow",
      "isRequired": true
    },
    {
      "name": "birthdate",
      "type": "text",
      "inputType": "date",
      "title": "Your birthdate:",
      "isRequired": true
    },
    {
      "name": "color",
      "type": "text",
      "inputType": "color",
      "title": "Your favorite color:"
    },
    {
      "name": "email",
      "type": "text",
      "inputType": "email",
      "title": "Your e-mail:",
      "placeHolder": "jon.snow@nightwatch.org",
      "isRequired": true,
      "validators": [ { "type": "email" } ]
    }
  ]
};

                window.survey = new Survey.Model(json);
            
        
            survey.onComplete.add(function(result) {
            document.querySelector('#surveyResult').textContent =
            "Result JSON:\n" + JSON.stringify(result.data, null, 3);
            });
        
        
            var app = new Vue({
            el: '#surveyElement',
            data:
            {
            survey: survey
            }
            });
        

                    
<!DOCTYPE html>
<html lang="en">
<head>
    <title>Add your logo to the survey title., Vue Survey Library Example</title>

<meta name="viewport" content="width=device-width" />
    <script src="https://unpkg.com/vue/dist/vue.js"></script>
<script src="https://surveyjs.azureedge.net/1.8.6/survey.vue.js"></script>
<link href="https://surveyjs.azureedge.net/1.8.6/survey.css" type="text/css" rel="stylesheet" />
    <link rel="stylesheet" href="./index.css">

</head>
<body>
    
            <div id="surveyElement" style="display:inline-block;width:100%;">
                <survey :survey='survey' />
            </div>
    <div id="surveyResult"></div>

<script type="text/javascript" src="./index.js"></script>

</body>
</html>
settings

Logo position : (default is 'left')

survey.logoPosition = yourValue; survey.render();

survey.logoHeight = newValue; survey.render();

survey.logoWidth = newValue; survey.render();

Logo fit mode: (default is 'contain')

survey.logoFit = yourValue; survey.render();