Skip to content

Commit

Permalink
Remove the debugging-statement and revert dist/doc
Browse files Browse the repository at this point in the history
  • Loading branch information
Abraham Przewodnik committed Dec 10, 2020
1 parent df959eb commit be582f9
Show file tree
Hide file tree
Showing 10 changed files with 230 additions and 196 deletions.
33 changes: 16 additions & 17 deletions dist/parsley.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion dist/parsley.js.map

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion dist/parsley.min.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion dist/parsley.min.js.map

Large diffs are not rendered by default.

22 changes: 8 additions & 14 deletions doc/annotated-source/base.html
Original file line number Diff line number Diff line change
Expand Up @@ -121,20 +121,14 @@ <h1>base.js</h1>
Base.prototype = {
<span class="hljs-attr">asyncSupport</span>: <span class="hljs-literal">true</span>, <span class="hljs-comment">// Deprecated</span>

<span class="hljs-attr">_pipeAccordingToValidationResult</span>: <span class="hljs-function"><span class="hljs-keyword">function</span> (<span class="hljs-params">deferred</span>) </span>{
<span class="hljs-keyword">return</span> $.Deferred(<span class="hljs-function">(<span class="hljs-params">newDefer</span>) =&gt;</span> {
<span class="hljs-keyword">const</span> handle = <span class="hljs-function"><span class="hljs-params">()</span> =&gt;</span> {
<span class="hljs-keyword">var</span> r = <span class="hljs-literal">true</span> === <span class="hljs-keyword">this</span>.validationResult ?
$.Deferred().resolve():
$.Deferred().reject();
r.promise()
.progress(newDefer.notify)
.done(newDefer.resolve)
.fail(newDefer.reject)
}
deferred.done(handle)
deferred.fail(handle)
})
<span class="hljs-attr">_pipeAccordingToValidationResult</span>: <span class="hljs-function"><span class="hljs-keyword">function</span> (<span class="hljs-params"></span>) </span>{
<span class="hljs-keyword">var</span> pipe = <span class="hljs-function"><span class="hljs-params">()</span> =&gt;</span> {
<span class="hljs-keyword">var</span> r = $.Deferred();
<span class="hljs-keyword">if</span> (<span class="hljs-literal">true</span> !== <span class="hljs-keyword">this</span>.validationResult)
r.reject();
<span class="hljs-keyword">return</span> r.resolve().promise();
};
<span class="hljs-keyword">return</span> [pipe, pipe];
},

<span class="hljs-attr">actualizeOptions</span>: <span class="hljs-function"><span class="hljs-keyword">function</span> (<span class="hljs-params"></span>) </span>{
Expand Down
15 changes: 6 additions & 9 deletions doc/annotated-source/field.html
Original file line number Diff line number Diff line change
Expand Up @@ -261,13 +261,12 @@ <h1 id="public-api">Public API</h1>

<div class="content"><div class='highlight'><pre> <span class="hljs-keyword">this</span>._trigger(<span class="hljs-string">'validate'</span>);

<span class="hljs-keyword">return</span> <span class="hljs-keyword">this</span>._pipeAccordingToValidationResult(
<span class="hljs-keyword">this</span>.whenValid({force, <span class="hljs-attr">value</span>: <span class="hljs-keyword">this</span>.value, <span class="hljs-attr">_refreshed</span>: <span class="hljs-literal">true</span>})
.always(<span class="hljs-function"><span class="hljs-params">()</span> =&gt;</span> { <span class="hljs-keyword">this</span>._reflowUI(); })
.done(<span class="hljs-function"><span class="hljs-params">()</span> =&gt;</span> { <span class="hljs-keyword">this</span>._trigger(<span class="hljs-string">'success'</span>); })
.fail(<span class="hljs-function"><span class="hljs-params">()</span> =&gt;</span> { <span class="hljs-keyword">this</span>._trigger(<span class="hljs-string">'error'</span>); })
.always(<span class="hljs-function"><span class="hljs-params">()</span> =&gt;</span> { <span class="hljs-keyword">this</span>._trigger(<span class="hljs-string">'validated'</span>); })
);
<span class="hljs-keyword">return</span> <span class="hljs-keyword">this</span>.whenValid({force, <span class="hljs-attr">value</span>: <span class="hljs-keyword">this</span>.value, <span class="hljs-attr">_refreshed</span>: <span class="hljs-literal">true</span>})
.always(<span class="hljs-function"><span class="hljs-params">()</span> =&gt;</span> { <span class="hljs-keyword">this</span>._reflowUI(); })
.done(<span class="hljs-function"><span class="hljs-params">()</span> =&gt;</span> { <span class="hljs-keyword">this</span>._trigger(<span class="hljs-string">'success'</span>); })
.fail(<span class="hljs-function"><span class="hljs-params">()</span> =&gt;</span> { <span class="hljs-keyword">this</span>._trigger(<span class="hljs-string">'error'</span>); })
.always(<span class="hljs-function"><span class="hljs-params">()</span> =&gt;</span> { <span class="hljs-keyword">this</span>._trigger(<span class="hljs-string">'validated'</span>); })
.pipe(...this._pipeAccordingToValidationResult());
},

<span class="hljs-attr">hasConstraints</span>: <span class="hljs-function"><span class="hljs-keyword">function</span> (<span class="hljs-params"></span>) </span>{
Expand Down Expand Up @@ -430,8 +429,6 @@ <h1 id="public-api">Public API</h1>
<div class="content"><div class='highlight'><pre> <span class="hljs-keyword">if</span> (<span class="hljs-string">'undefined'</span> === <span class="hljs-keyword">typeof</span> value || <span class="hljs-literal">null</span> === value)
value = <span class="hljs-keyword">this</span>.getValue();

<span class="hljs-built_in">console</span>.log(<span class="hljs-string">'validate'</span> + value)

<span class="hljs-keyword">if</span> (!<span class="hljs-keyword">this</span>.needsValidation(value) &amp;&amp; <span class="hljs-literal">true</span> !== force)
<span class="hljs-keyword">return</span> $.when();

Expand Down
19 changes: 9 additions & 10 deletions doc/annotated-source/form.html
Original file line number Diff line number Diff line change
Expand Up @@ -329,16 +329,15 @@ <h1>form.js</h1>
<span class="hljs-keyword">return</span> $.map(<span class="hljs-keyword">this</span>.fields, field =&gt; field.whenValidate({force, group}));
});

<span class="hljs-keyword">return</span> <span class="hljs-keyword">this</span>._pipeAccordingToValidationResult(
Utils.all(promises)
.done( <span class="hljs-function"><span class="hljs-params">()</span> =&gt;</span> { <span class="hljs-keyword">this</span>._trigger(<span class="hljs-string">'success'</span>); })
.fail( <span class="hljs-function"><span class="hljs-params">()</span> =&gt;</span> {
<span class="hljs-keyword">this</span>.validationResult = <span class="hljs-literal">false</span>;
<span class="hljs-keyword">this</span>.focus();
<span class="hljs-keyword">this</span>._trigger(<span class="hljs-string">'error'</span>);
})
.always(<span class="hljs-function"><span class="hljs-params">()</span> =&gt;</span> { <span class="hljs-keyword">this</span>._trigger(<span class="hljs-string">'validated'</span>); })
);
<span class="hljs-keyword">return</span> Utils.all(promises)
.done( <span class="hljs-function"><span class="hljs-params">()</span> =&gt;</span> { <span class="hljs-keyword">this</span>._trigger(<span class="hljs-string">'success'</span>); })
.fail( <span class="hljs-function"><span class="hljs-params">()</span> =&gt;</span> {
<span class="hljs-keyword">this</span>.validationResult = <span class="hljs-literal">false</span>;
<span class="hljs-keyword">this</span>.focus();
<span class="hljs-keyword">this</span>._trigger(<span class="hljs-string">'error'</span>);
})
.always(<span class="hljs-function"><span class="hljs-params">()</span> =&gt;</span> { <span class="hljs-keyword">this</span>._trigger(<span class="hljs-string">'validated'</span>); })
.pipe(...this._pipeAccordingToValidationResult());
},</pre></div></div>

</li>
Expand Down
2 changes: 1 addition & 1 deletion doc/annotated-source/remote.html
Original file line number Diff line number Diff line change
Expand Up @@ -274,7 +274,7 @@ <h1>remote.js</h1>
<div class="pilwrap ">
<a class="pilcrow" href="#section-8">&#182;</a>
</div>
<p>Initialise query cache</p>
<p>Initialise querry cache</p>

</div>

Expand Down
38 changes: 17 additions & 21 deletions doc/assets/spec-build.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading

0 comments on commit be582f9

Please sign in to comment.