mirror of
https://github.com/transloadit/uppy.git
synced 2026-01-23 02:25:07 +00:00
Getting a sandbox going with the worst possible layout
This commit is contained in:
parent
a2428babfd
commit
320c8a16ef
5 changed files with 32 additions and 3 deletions
1
LICENSE
1
LICENSE
|
|
@ -19,4 +19,3 @@ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|||
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
||||
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
||||
SOFTWARE.
|
||||
|
||||
|
|
|
|||
|
|
@ -28,6 +28,8 @@ Now to get a sandbox environment set up, type:
|
|||
|
||||
```bash
|
||||
npm run preview
|
||||
# For instant rebuilds, in a new tab, type:
|
||||
npm run watch
|
||||
```
|
||||
|
||||
This will `npm run build` the project into `./build`, and then serve that
|
||||
|
|
|
|||
|
|
@ -10,6 +10,16 @@
|
|||
<h1>
|
||||
Loading..
|
||||
</h1>
|
||||
<p>
|
||||
With this file we can easily test the built js client locally (via <code>npm run preview</code>)
|
||||
and online.
|
||||
</p>
|
||||
|
||||
<div id="upload-target">
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
|
||||
<footer>
|
||||
<hr />
|
||||
|
|
@ -21,10 +31,13 @@
|
|||
</body>
|
||||
<script src="./transloadit-js-client.js"></script>
|
||||
<script>
|
||||
var branch = location.pathname.split('/')[2];
|
||||
var tl = Transloadit("#upload-target");
|
||||
</script>
|
||||
<script>
|
||||
var branch = location.pathname.split('/')[2] || 'local-unknown';
|
||||
var elTitle = document.querySelector('title');
|
||||
var elH1 = document.querySelector('h1');
|
||||
var title = 'You are reviewing the latest push of branch: ' + branch;
|
||||
var title = 'You are reviewing branch: ' + branch;
|
||||
elTitle.innerHTML = title;
|
||||
elH1.innerHTML = title;
|
||||
</script>
|
||||
|
|
|
|||
|
|
@ -0,0 +1,9 @@
|
|||
window.Transloadit = function (selector) {
|
||||
var el = document.querySelector(selector);
|
||||
var inner = ''
|
||||
inner += '<div class="transloadit-js-client">';
|
||||
inner += 'Hello world :)';
|
||||
inner += 'I am the new Transloadit js client, and as you can see, I need to be improved badly :)';
|
||||
inner += '</div>';
|
||||
el.innerHTML = inner;
|
||||
};
|
||||
|
|
@ -0,0 +1,6 @@
|
|||
.transloadit-js-client {
|
||||
font-family : "Comic Sans MS";
|
||||
color : purple;
|
||||
border : 1px dashed pink;
|
||||
font-size : 32px;
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue