* Update survey to use React/TS * Working survey form in react land * A little cleanup * Update Search.tsx * Update Survey.tsx * Remove token field from schema entirely, just let it fail validation * Update events.js * Update survey.html * use Link component * Use enum for state * Update old to match new
108 lines
2.8 KiB
HTML
108 lines
2.8 KiB
HTML
{% unless enterpriseServerReleases.isOldestReleaseDeprecated and currentVersion contains enterpriseServerReleases.oldestSupported %}
|
|
<form class="js-survey f5">
|
|
<h2
|
|
data-help-start
|
|
data-help-yes
|
|
data-help-no
|
|
class="mb-1 f4"
|
|
>
|
|
{% data ui.survey.able_to_find %}
|
|
<a
|
|
class="f6 text-normal ml-3 color-text-link"
|
|
href="/github/site-policy/github-privacy-statement"
|
|
target="_blank"
|
|
>{% data ui.survey.privacy_policy %}</a>
|
|
</h2>
|
|
<p
|
|
class="radio-group"
|
|
data-help-start
|
|
data-help-yes
|
|
data-help-no
|
|
>
|
|
<input
|
|
hidden
|
|
id="survey-yes"
|
|
type="radio"
|
|
name="survey-vote"
|
|
value="Yes"
|
|
aria-label="{% data ui.survey.yes %}"
|
|
/>
|
|
<label class="btn x-radio-label" for="survey-yes">
|
|
{% octicon "thumbsup" height="24" %}
|
|
</label>
|
|
<input
|
|
hidden
|
|
id="survey-no"
|
|
type="radio"
|
|
name="survey-vote"
|
|
value="No"
|
|
aria-label="{% data ui.survey.no %}"
|
|
/>
|
|
<label class="btn x-radio-label" for="survey-no">
|
|
{% octicon "thumbsdown" height="24" %}
|
|
</label>
|
|
</p>
|
|
<p class="color-text-secondary f6" hidden data-help-yes>
|
|
{% data ui.survey.yes_feedback %}
|
|
</p>
|
|
<p class="color-text-secondary f6" hidden data-help-no>
|
|
{% data ui.survey.no_feedback %}
|
|
</p>
|
|
<input
|
|
type="text"
|
|
class="d-none"
|
|
name="survey-token"
|
|
aria-hidden="true"
|
|
/>
|
|
<p hidden data-help-yes data-help-no>
|
|
<label
|
|
class="d-block mb-1 f6"
|
|
for="survey-comment"
|
|
>
|
|
<span hidden data-help-yes>{% data ui.survey.comment_yes_label %}</span>
|
|
<span hidden data-help-no>{% data ui.survey.comment_no_label %}</span>
|
|
<span class="text-normal color-text-tertiary float-right ml-1">
|
|
{% data ui.survey.optional %}
|
|
</span>
|
|
</label>
|
|
<textarea
|
|
class="form-control input-sm width-full"
|
|
name="survey-comment"
|
|
id="survey-comment"
|
|
></textarea>
|
|
</p>
|
|
<p hidden data-help-yes data-help-no>
|
|
<label
|
|
class="d-block mb-1 f6"
|
|
for="survey-email"
|
|
>
|
|
{% data ui.survey.email_label %}
|
|
<span class="text-normal color-text-tertiary float-right ml-1">
|
|
{% data ui.survey.optional %}
|
|
</span>
|
|
</label>
|
|
<input
|
|
type="email"
|
|
class="form-control input-sm width-full"
|
|
name="survey-email"
|
|
id="survey-email"
|
|
placeholder="{% data ui.survey.email_placeholder %}"
|
|
/>
|
|
<span class="f6 color-text-secondary">{% data ui.survey.not_support %}</span>
|
|
</p>
|
|
<p
|
|
class="text-right"
|
|
hidden
|
|
data-help-yes
|
|
data-help-no
|
|
>
|
|
<button type="submit" class="btn btn-sm">
|
|
{% data ui.survey.send %}
|
|
</button>
|
|
</p>
|
|
<p class="color-text-secondary f6" hidden data-help-end>
|
|
{% data ui.survey.feedback %}
|
|
</p>
|
|
</form>
|
|
{% endunless %}
|