hexsha
string
size
int64
ext
string
lang
string
max_stars_repo_path
string
max_stars_repo_name
string
max_stars_repo_head_hexsha
string
max_stars_repo_licenses
list
max_stars_count
int64
max_stars_repo_stars_event_min_datetime
string
max_stars_repo_stars_event_max_datetime
string
max_issues_repo_path
string
max_issues_repo_name
string
max_issues_repo_head_hexsha
string
max_issues_repo_licenses
list
max_issues_count
int64
max_issues_repo_issues_event_min_datetime
string
max_issues_repo_issues_event_max_datetime
string
max_forks_repo_path
string
max_forks_repo_name
string
max_forks_repo_head_hexsha
string
max_forks_repo_licenses
list
max_forks_count
int64
max_forks_repo_forks_event_min_datetime
string
max_forks_repo_forks_event_max_datetime
string
content
string
avg_line_length
float64
max_line_length
int64
alphanum_fraction
float64
93a29dbfaa8e168ef47c57f647d3fe32b51111e5
1,320
js
JavaScript
lib/utils/reviews.js
dineshselvantdm/furiosas-autos
79167fbd8bb985fd7405f48480203ff6e4b18a6d
[ "MIT" ]
null
null
null
lib/utils/reviews.js
dineshselvantdm/furiosas-autos
79167fbd8bb985fd7405f48480203ff6e4b18a6d
[ "MIT" ]
null
null
null
lib/utils/reviews.js
dineshselvantdm/furiosas-autos
79167fbd8bb985fd7405f48480203ff6e4b18a6d
[ "MIT" ]
null
null
null
module.exports = (function(){ //Merge Customer and Corporate data in to single array. var mergeCustomerAndCorporateData = function(reviews){ return reviews.reduce(function(mergedReviews,review){ return mergedReviews.concat(review); }); } //Convert data and search key to lower case and search for key and return true if present. var isSearchKeyPresent = function(mergedReview,req){ var searchKey = getSearchKey(req).toLowerCase(); return (mergedReview.content.toLowerCase().search(searchKey) >= 0 || mergedReview.source.toLowerCase().search(searchKey) >= 0); } var generateSearchedData = function(mergedReviews,req){ //If no searh key from query params return all reviews if(getSearchKey(req) === ''){ return mergedReviews; } //If searh key is present in query params return filtered reviews var searchedReviews = mergedReviews.filter(function(mergedReview){ return isSearchKeyPresent(mergedReview,req); }); return searchedReviews; } var getSearchedData = function(reviews,req){ var mergedReviews = mergeCustomerAndCorporateData(reviews); return generateSearchedData(mergedReviews,req); } var getSearchKey = function(req){ var key = req.query.search || ''; return key; } return{ getSearchedData : getSearchedData, getSearchKey : getSearchKey } })();
30.697674
91
0.742424
93a3236ee6508d88e1df5117f5c2a7be0fda1e1a
4,445
js
JavaScript
www/js/controllers/incidentController.js
ChESch/mobile-app
a639bd0271f33eac2832665e7d604d37e653e639
[ "MIT" ]
16
2015-08-11T16:51:07.000Z
2021-12-31T16:10:32.000Z
www/js/controllers/incidentController.js
ChESch/mobile-app
a639bd0271f33eac2832665e7d604d37e653e639
[ "MIT" ]
75
2015-08-02T20:44:37.000Z
2022-01-04T11:42:16.000Z
www/js/controllers/incidentController.js
ChESch/mobile-app
a639bd0271f33eac2832665e7d604d37e653e639
[ "MIT" ]
16
2015-08-02T20:27:25.000Z
2022-02-17T01:25:45.000Z
angular.module('grisu-noe').controller('incidentController', function($scope, $stateParams, dataService, util, $ionicModal, geoService, leafletData, storageService) { var circles = geoService.getRadiusCircles(); var settings = storageService.getObject('settings'); $scope.isMapAvailable = false; $scope.isMapRefreshing = false; $scope.isRouteAvailable = false; $scope.isRouteRefreshing = false; $scope.layers = geoService.getStandardLayers(settings.showIncidentHydrants); $scope.updateMapToLocation = function() { $scope.isMapRefreshing = true; var geoCodeAddress = $scope.incident.p + ' ' + $scope.incident.o + ', Niederösterreich'; console.debug('Update of map with geocoding string: ' + geoCodeAddress); geoService.geocodeAddress(geoCodeAddress).then(function(data) { if (data.results.length === 0) { // no results found return; } var validEntry = data.results[0]; $scope.destLat = validEntry.geometry.location.lat; $scope.destLng = validEntry.geometry.location.lng; $scope.isRouteRefreshing = true; geoService.getCurrentPosition().then(function(position) { $scope.isRouteAvailable = true; $scope.originLat = position.lat; $scope.originLng = position.lng; }).finally(function() { $scope.isRouteRefreshing = false; }); leafletData.getMap().then(function(map) { map.setView(new L.LatLng($scope.destLat, $scope.destLng), 14); var redIcon = L.AwesomeMarkers.icon({ prefix: 'ion', icon: 'flame', markerColor: 'red', iconColor: 'white' }); var marker = L.marker([$scope.destLat, $scope.destLng], { icon: redIcon }); marker.bindPopup(validEntry.formatted_address, { closeButton: false }); map.addLayer(marker); if (settings.showIncidentDistance) { angular.forEach(circles, function(circle) { geoService.addCircleToMap(map, circle); }); geoService.addDistanceLegendToMap(map, circles); } if (settings.showIncidentHydrants) { geoService.findHydrantsForPosition(map.getCenter().lat, map.getCenter().lng).then(function(data) { geoService.addHydrantsToMap(data, map); }); } $scope.isMapAvailable = true; }); }).finally(function() { $scope.isMapRefreshing = false; }); }; $scope.doRefresh = function() { util.genericRefresh($scope, dataService.getIncidentData($stateParams.incidentId), function(data) { $scope.incident = data; $scope.bygone = util.calculateBygoneTime(data.d + ' ' + data.t, 'DD.MM.YYYY HH:mm:ss'); // trigger only on first refresh or map isn't available if (!$scope.isMapAvailable) { $scope.updateMapToLocation(); } }); }; $scope.$on('cordova.resume', function() { $scope.doRefresh(); }); $scope.$on('$ionicView.enter', function() { $scope.doRefresh(); }); $scope.toggleDispo = function(dispo) { if ($scope.isDispoShown(dispo)) { $scope.shownDispo = null; } else { $scope.shownDispo = dispo; } }; $scope.isDispoShown = function(dispo) { if (angular.isUndefinedOrNull($scope.shownDispo)) { return false; } // don't compare object equality, compare name equality because of refresh return angular.toJson($scope.shownDispo, false) === angular.toJson(dispo, false); }; $ionicModal.fromTemplateUrl('templates/incident-map.html', { scope: $scope, animation: 'slide-in-up' }).then(function(modal) { $scope.mapDialog = modal; }); $scope.openMapDialog = function() { $scope.mapDialog.show(); }; $scope.closeMapDialog = function() { $scope.mapDialog.hide(); }; $scope.$on('$destroy', function() { $scope.mapDialog.remove(); }); });
33.931298
118
0.554331
93a363c33ce5e10ad00dfdcbe805e2007149974f
3,961
js
JavaScript
src/components/About/Skill.js
takayuki-0107/gatsby-portfolio
f3fca03f3a9a4310b51b3821452d1a2a6330efc0
[ "MIT" ]
null
null
null
src/components/About/Skill.js
takayuki-0107/gatsby-portfolio
f3fca03f3a9a4310b51b3821452d1a2a6330efc0
[ "MIT" ]
1
2022-02-10T23:01:42.000Z
2022-02-10T23:01:42.000Z
src/components/About/Skill.js
takayuki-0107/gatsby-portfolio
f3fca03f3a9a4310b51b3821452d1a2a6330efc0
[ "MIT" ]
null
null
null
import React from "react" // import Img from "gatsby-image" import styled from "@emotion/styled" import { ContentButton } from "../molecules/Button" import Color from "../../styles/Color" import Size from "../../styles/Size" import Typograph from "../../styles/Typograph" const Wrapper = styled.div` padding: ${Size(50)} 0; margin: 0 auto; width: 90%; position: relative; ` const SectionTitle = styled.div` ${Typograph.SectionTitle} margin-bottom: ${Size(30)}; ` const Development = styled.div` width: 90%; max-width: 800px; margin: 0 auto; @media (min-width: 785px) { display: flex; justify-content: space-around; align-items: center; } div { margin: 0 auto ${Size(30)}; text-align: center; padding: ${Size(20)} ${Size(20)}; width: 80%; max-width: 350px; height: 350px; box-shadow: 0px 0px 6px rgba(0, 0, 0, 0.7); @media (min-width: 785px) { width: 45%; } } h3 { font-size: ${Size(20)}; line-height: 1; } span { font-size: ${Size(14)}; } p { text-align: left; } ` const Skill = styled.div` display: flex; flex-direction: column; color: #fff; width: inherit; max-width: 800px; height: auto; text-align: center; margin: 0 auto ${Size(50)}; ` const SkillWrapper = styled.div` box-shadow: 3px 3px 6px rgba(0, 0, 0, 0.7); margin-bottom: ${Size(30)}; @media (min-width: 960px) { display: flex; justify-content: center; margin: 1px; box-shadow: none; height: 80px; } ` const SkillTitle = styled.div` padding: ${Size(20)}; background-color: ${Color.LightBlue}; @media (min-width: 960px) { width: 35%; max-width: 300px; height: 80px; } ` const SkillName = styled.div` padding: ${Size(20)}; color: ${Color.Black}; background-color: ${Color.ThinBlue}; @media (min-width: 960px) { width: 66%; height: 80px; } ` export default () => { return ( <> <section> <Wrapper> <SectionTitle> <h2>Skill</h2> <p>提供出来る技術と開発物一覧</p> </SectionTitle> <Development> <div> <h3>WEBサイト制作</h3> <span>WEBSITE PRODUCTION</span> {/* <Img /> */} <p> 企業サイト、個人ポートフォリオ 、LPなどWebサイト制作全般を承ります。デザイン性はもちろん、検索エンジンからの流入を強化する「SEOに強いサイト」の制作が得意です。 </p> </div> <div> <h3>WEBアプリ開発</h3> <span>WEB APP DEV</span> {/* <Img /> */} <p> リアルタイム性が重視されるSNSアプリやチャットアプリなどを開発できます。 これまで開発してきたWebアプリの一部を制作事例として公開しています。 </p> </div> </Development> <Skill> <SkillWrapper> <SkillTitle> <p>マークアップ</p> </SkillTitle> <SkillName> <p>{`HTML5, CSS3, Bootstrap4, Sass(scss)`}</p> </SkillName> </SkillWrapper> <SkillWrapper> <SkillTitle> <p>フロントエンド</p> </SkillTitle> <SkillName> <p> {`JavaScript(ES6), React, Redux, TypeScript,`} <br /> Next.js, Gatsby, Webpack, Babel </p> </SkillName> </SkillWrapper> <SkillWrapper> <SkillTitle> <p>バックエンド</p> </SkillTitle> <SkillName> <p>Node.js, Firebace</p> </SkillName> </SkillWrapper> <SkillWrapper> <SkillTitle> <p>その他ツール</p> </SkillTitle> <SkillName> <p>git, npm, yarn, XDなど</p> </SkillName> </SkillWrapper> </Skill> <ContentButton to={"/works"}>Contact</ContentButton> </Wrapper> </section> </> ) }
23.861446
84
0.494572
93a3d546f3d310635e0c29d0b5101b6e56a828c4
503
js
JavaScript
api-proxy/public/forwardRequest.js
wilsonmar/rest-coder
39d041a5eaccfb9d60647603faf2282745a1012c
[ "Apache-2.0" ]
13
2015-05-11T05:16:58.000Z
2019-11-16T22:25:03.000Z
api-proxy/public/forwardRequest.js
wilsonmar/rest-coder
39d041a5eaccfb9d60647603faf2282745a1012c
[ "Apache-2.0" ]
null
null
null
api-proxy/public/forwardRequest.js
wilsonmar/rest-coder
39d041a5eaccfb9d60647603faf2282745a1012c
[ "Apache-2.0" ]
8
2015-04-09T18:41:55.000Z
2021-02-04T23:09:53.000Z
function generalRequest(requestObj, callback) { console.log("forwarding request..."); var request = require("request"); request({ uri: requestObj.baseUrl+requestObj.path, method: requestObj.method, headers: {"Content-Type" : '\"'+requestObj.contentType+'\"'}, body: requestObj.payload, timeout: 10000, followRedirect: true, maxRedirects: 10 }, function(error, res, body) { callback(error, res, body); }); } exports.generalRequest = generalRequest;
22.863636
63
0.662028
93a5704974ea7d960a7ce7280fc1f0d7ff45f80a
670
js
JavaScript
generate-pdf.js
dcecile/dcecile-resume-portfolio
71b54ccd8faf55b06f8b0f95469549e3c5071293
[ "MIT" ]
6
2018-02-23T01:47:56.000Z
2020-09-24T07:05:14.000Z
generate-pdf.js
dcecile/dcecile-resume-portfolio
71b54ccd8faf55b06f8b0f95469549e3c5071293
[ "MIT" ]
34
2018-02-15T14:30:18.000Z
2018-12-25T18:06:01.000Z
generate-pdf.js
dcecile/dcecile-resume-portfolio
71b54ccd8faf55b06f8b0f95469549e3c5071293
[ "MIT" ]
1
2019-07-19T10:38:37.000Z
2019-07-19T10:38:37.000Z
const puppeteer = require('puppeteer') const express = require('express') const serveStatic = require('serve-static') async function main() { try { const app = express() app.use(serveStatic('./build', { index: ['index.html'] })) app.listen(3001) const browser = await puppeteer.launch({ args: ['--no-sandbox', '--disable-setuid-sandbox'] }) const page = await browser.newPage() await page.goto('http://localhost:3001', { waitUntil: 'networkidle2' }) await page.pdf({ path: 'build/resume.pdf' }) await browser.close() } catch (exception) { console.error(exception) process.exit(1) } process.exit(0) } main()
23.928571
75
0.638806
93a6473d543dd9ad0b0551872275cb637c8763d1
49,906
js
JavaScript
docs/client/assets/js/search.js
jonyg80/nft.storage
a225fa8d1580bb7db79531bfd25c1e836103f60e
[ "Apache-2.0", "MIT" ]
null
null
null
docs/client/assets/js/search.js
jonyg80/nft.storage
a225fa8d1580bb7db79531bfd25c1e836103f60e
[ "Apache-2.0", "MIT" ]
3
2021-12-09T07:00:37.000Z
2022-02-27T20:26:12.000Z
docs/client/assets/js/search.js
Natain/nft.storage
a225fa8d1580bb7db79531bfd25c1e836103f60e
[ "Apache-2.0", "MIT" ]
2
2021-09-07T06:37:59.000Z
2021-09-22T17:31:01.000Z
window.searchData = {"kinds":{"1":"Module","32":"Variable","64":"Function","128":"Class","256":"Interface","512":"Constructor","1024":"Property","2048":"Method","65536":"Type literal","4194304":"Type alias","16777216":"Reference"},"rows":[{"id":0,"kind":1,"name":"gateway","url":"modules/gateway.html","classes":"tsd-kind-module"},{"id":1,"kind":32,"name":"GATEWAY","url":"modules/gateway.html#gateway-2","classes":"tsd-kind-variable tsd-parent-kind-module","parent":"gateway"},{"id":2,"kind":64,"name":"toGatewayURL","url":"modules/gateway.html#togatewayurl","classes":"tsd-kind-function tsd-parent-kind-module","parent":"gateway"},{"id":3,"kind":4194304,"name":"GatewayURL","url":"modules/gateway.html#gatewayurl","classes":"tsd-kind-type-alias tsd-parent-kind-module tsd-has-type-parameter","parent":"gateway"},{"id":4,"kind":4194304,"name":"GatewayURLOptions","url":"modules/gateway.html#gatewayurloptions","classes":"tsd-kind-type-alias tsd-parent-kind-module tsd-has-type-parameter","parent":"gateway"},{"id":5,"kind":65536,"name":"__type","url":"modules/gateway.html#gatewayurloptions.__type","classes":"tsd-kind-type-literal tsd-parent-kind-type-alias","parent":"gateway.GatewayURLOptions"},{"id":6,"kind":1024,"name":"gateway","url":"modules/gateway.html#gatewayurloptions.__type.gateway-1","classes":"tsd-kind-property tsd-parent-kind-type-literal","parent":"gateway.GatewayURLOptions.__type"},{"id":7,"kind":1,"name":"lib/interface","url":"modules/lib_interface.html","classes":"tsd-kind-module"},{"id":8,"kind":4194304,"name":"CarReader","url":"modules/lib_interface.html#carreader","classes":"tsd-kind-type-alias tsd-parent-kind-module","parent":"lib/interface"},{"id":9,"kind":4194304,"name":"Tagged","url":"modules/lib_interface.html#tagged","classes":"tsd-kind-type-alias tsd-parent-kind-module tsd-has-type-parameter","parent":"lib/interface"},{"id":10,"kind":256,"name":"Service","url":"interfaces/lib_interface.service.html","classes":"tsd-kind-interface tsd-parent-kind-module","parent":"lib/interface"},{"id":11,"kind":1024,"name":"endpoint","url":"interfaces/lib_interface.service.html#endpoint","classes":"tsd-kind-property tsd-parent-kind-interface","parent":"lib/interface.Service"},{"id":12,"kind":1024,"name":"token","url":"interfaces/lib_interface.service.html#token","classes":"tsd-kind-property tsd-parent-kind-interface","parent":"lib/interface.Service"},{"id":13,"kind":256,"name":"PublicService","url":"interfaces/lib_interface.publicservice.html","classes":"tsd-kind-interface tsd-parent-kind-module","parent":"lib/interface"},{"id":14,"kind":1024,"name":"endpoint","url":"interfaces/lib_interface.publicservice.html#endpoint","classes":"tsd-kind-property tsd-parent-kind-interface","parent":"lib/interface.PublicService"},{"id":15,"kind":4194304,"name":"CIDString","url":"modules/lib_interface.html#cidstring","classes":"tsd-kind-type-alias tsd-parent-kind-module","parent":"lib/interface"},{"id":16,"kind":256,"name":"API","url":"interfaces/lib_interface.api.html","classes":"tsd-kind-interface tsd-parent-kind-module","parent":"lib/interface"},{"id":17,"kind":2048,"name":"store","url":"interfaces/lib_interface.api.html#store","classes":"tsd-kind-method tsd-parent-kind-interface tsd-has-type-parameter","parent":"lib/interface.API"},{"id":18,"kind":2048,"name":"storeBlob","url":"interfaces/lib_interface.api.html#storeblob","classes":"tsd-kind-method tsd-parent-kind-interface","parent":"lib/interface.API"},{"id":19,"kind":2048,"name":"storeCar","url":"interfaces/lib_interface.api.html#storecar","classes":"tsd-kind-method tsd-parent-kind-interface","parent":"lib/interface.API"},{"id":20,"kind":2048,"name":"storeDirectory","url":"interfaces/lib_interface.api.html#storedirectory","classes":"tsd-kind-method tsd-parent-kind-interface","parent":"lib/interface.API"},{"id":21,"kind":2048,"name":"status","url":"interfaces/lib_interface.api.html#status","classes":"tsd-kind-method tsd-parent-kind-interface","parent":"lib/interface.API"},{"id":22,"kind":2048,"name":"delete","url":"interfaces/lib_interface.api.html#delete","classes":"tsd-kind-method tsd-parent-kind-interface","parent":"lib/interface.API"},{"id":23,"kind":2048,"name":"check","url":"interfaces/lib_interface.api.html#check","classes":"tsd-kind-method tsd-parent-kind-interface","parent":"lib/interface.API"},{"id":24,"kind":256,"name":"CheckResult","url":"interfaces/lib_interface.checkresult.html","classes":"tsd-kind-interface tsd-parent-kind-module","parent":"lib/interface"},{"id":25,"kind":1024,"name":"cid","url":"interfaces/lib_interface.checkresult.html#cid","classes":"tsd-kind-property tsd-parent-kind-interface","parent":"lib/interface.CheckResult"},{"id":26,"kind":1024,"name":"pin","url":"interfaces/lib_interface.checkresult.html#pin","classes":"tsd-kind-property tsd-parent-kind-interface","parent":"lib/interface.CheckResult"},{"id":27,"kind":65536,"name":"__type","url":"interfaces/lib_interface.checkresult.html#__type","classes":"tsd-kind-type-literal tsd-parent-kind-interface","parent":"lib/interface.CheckResult"},{"id":28,"kind":1024,"name":"status","url":"interfaces/lib_interface.checkresult.html#__type.status","classes":"tsd-kind-property tsd-parent-kind-type-literal","parent":"lib/interface.CheckResult.__type"},{"id":29,"kind":1024,"name":"deals","url":"interfaces/lib_interface.checkresult.html#deals","classes":"tsd-kind-property tsd-parent-kind-interface","parent":"lib/interface.CheckResult"},{"id":30,"kind":256,"name":"StatusResult","url":"interfaces/lib_interface.statusresult.html","classes":"tsd-kind-interface tsd-parent-kind-module","parent":"lib/interface"},{"id":31,"kind":1024,"name":"cid","url":"interfaces/lib_interface.statusresult.html#cid","classes":"tsd-kind-property tsd-parent-kind-interface","parent":"lib/interface.StatusResult"},{"id":32,"kind":1024,"name":"size","url":"interfaces/lib_interface.statusresult.html#size","classes":"tsd-kind-property tsd-parent-kind-interface","parent":"lib/interface.StatusResult"},{"id":33,"kind":1024,"name":"deals","url":"interfaces/lib_interface.statusresult.html#deals","classes":"tsd-kind-property tsd-parent-kind-interface","parent":"lib/interface.StatusResult"},{"id":34,"kind":1024,"name":"pin","url":"interfaces/lib_interface.statusresult.html#pin","classes":"tsd-kind-property tsd-parent-kind-interface","parent":"lib/interface.StatusResult"},{"id":35,"kind":1024,"name":"created","url":"interfaces/lib_interface.statusresult.html#created","classes":"tsd-kind-property tsd-parent-kind-interface","parent":"lib/interface.StatusResult"},{"id":36,"kind":4194304,"name":"Deal","url":"modules/lib_interface.html#deal","classes":"tsd-kind-type-alias tsd-parent-kind-module","parent":"lib/interface"},{"id":37,"kind":256,"name":"DealInfo","url":"interfaces/lib_interface.dealinfo.html","classes":"tsd-kind-interface tsd-parent-kind-module","parent":"lib/interface"},{"id":38,"kind":1024,"name":"lastChanged","url":"interfaces/lib_interface.dealinfo.html#lastchanged","classes":"tsd-kind-property tsd-parent-kind-interface","parent":"lib/interface.DealInfo"},{"id":39,"kind":1024,"name":"miner","url":"interfaces/lib_interface.dealinfo.html#miner","classes":"tsd-kind-property tsd-parent-kind-interface","parent":"lib/interface.DealInfo"},{"id":40,"kind":1024,"name":"network","url":"interfaces/lib_interface.dealinfo.html#network","classes":"tsd-kind-property tsd-parent-kind-interface","parent":"lib/interface.DealInfo"},{"id":41,"kind":1024,"name":"pieceCid","url":"interfaces/lib_interface.dealinfo.html#piececid","classes":"tsd-kind-property tsd-parent-kind-interface","parent":"lib/interface.DealInfo"},{"id":42,"kind":1024,"name":"batchRootCid","url":"interfaces/lib_interface.dealinfo.html#batchrootcid","classes":"tsd-kind-property tsd-parent-kind-interface","parent":"lib/interface.DealInfo"},{"id":43,"kind":256,"name":"QueuedDeal","url":"interfaces/lib_interface.queueddeal.html","classes":"tsd-kind-interface tsd-parent-kind-module","parent":"lib/interface"},{"id":44,"kind":1024,"name":"status","url":"interfaces/lib_interface.queueddeal.html#status","classes":"tsd-kind-property tsd-parent-kind-interface","parent":"lib/interface.QueuedDeal"},{"id":45,"kind":1024,"name":"lastChanged","url":"interfaces/lib_interface.queueddeal.html#lastchanged","classes":"tsd-kind-property tsd-parent-kind-interface","parent":"lib/interface.QueuedDeal"},{"id":46,"kind":256,"name":"PendingDeal","url":"interfaces/lib_interface.pendingdeal.html","classes":"tsd-kind-interface tsd-parent-kind-module","parent":"lib/interface"},{"id":47,"kind":1024,"name":"status","url":"interfaces/lib_interface.pendingdeal.html#status","classes":"tsd-kind-property tsd-parent-kind-interface","parent":"lib/interface.PendingDeal"},{"id":48,"kind":1024,"name":"lastChanged","url":"interfaces/lib_interface.pendingdeal.html#lastchanged","classes":"tsd-kind-property tsd-parent-kind-interface tsd-is-inherited","parent":"lib/interface.PendingDeal"},{"id":49,"kind":1024,"name":"miner","url":"interfaces/lib_interface.pendingdeal.html#miner","classes":"tsd-kind-property tsd-parent-kind-interface tsd-is-inherited","parent":"lib/interface.PendingDeal"},{"id":50,"kind":1024,"name":"network","url":"interfaces/lib_interface.pendingdeal.html#network","classes":"tsd-kind-property tsd-parent-kind-interface tsd-is-inherited","parent":"lib/interface.PendingDeal"},{"id":51,"kind":1024,"name":"pieceCid","url":"interfaces/lib_interface.pendingdeal.html#piececid","classes":"tsd-kind-property tsd-parent-kind-interface tsd-is-inherited","parent":"lib/interface.PendingDeal"},{"id":52,"kind":1024,"name":"batchRootCid","url":"interfaces/lib_interface.pendingdeal.html#batchrootcid","classes":"tsd-kind-property tsd-parent-kind-interface tsd-is-inherited","parent":"lib/interface.PendingDeal"},{"id":53,"kind":256,"name":"FailedDeal","url":"interfaces/lib_interface.faileddeal.html","classes":"tsd-kind-interface tsd-parent-kind-module","parent":"lib/interface"},{"id":54,"kind":1024,"name":"status","url":"interfaces/lib_interface.faileddeal.html#status","classes":"tsd-kind-property tsd-parent-kind-interface","parent":"lib/interface.FailedDeal"},{"id":55,"kind":1024,"name":"statusText","url":"interfaces/lib_interface.faileddeal.html#statustext","classes":"tsd-kind-property tsd-parent-kind-interface","parent":"lib/interface.FailedDeal"},{"id":56,"kind":1024,"name":"lastChanged","url":"interfaces/lib_interface.faileddeal.html#lastchanged","classes":"tsd-kind-property tsd-parent-kind-interface tsd-is-inherited","parent":"lib/interface.FailedDeal"},{"id":57,"kind":1024,"name":"miner","url":"interfaces/lib_interface.faileddeal.html#miner","classes":"tsd-kind-property tsd-parent-kind-interface tsd-is-inherited","parent":"lib/interface.FailedDeal"},{"id":58,"kind":1024,"name":"network","url":"interfaces/lib_interface.faileddeal.html#network","classes":"tsd-kind-property tsd-parent-kind-interface tsd-is-inherited","parent":"lib/interface.FailedDeal"},{"id":59,"kind":1024,"name":"pieceCid","url":"interfaces/lib_interface.faileddeal.html#piececid","classes":"tsd-kind-property tsd-parent-kind-interface tsd-is-inherited","parent":"lib/interface.FailedDeal"},{"id":60,"kind":1024,"name":"batchRootCid","url":"interfaces/lib_interface.faileddeal.html#batchrootcid","classes":"tsd-kind-property tsd-parent-kind-interface tsd-is-inherited","parent":"lib/interface.FailedDeal"},{"id":61,"kind":256,"name":"PublishedDeal","url":"interfaces/lib_interface.publisheddeal.html","classes":"tsd-kind-interface tsd-parent-kind-module","parent":"lib/interface"},{"id":62,"kind":1024,"name":"status","url":"interfaces/lib_interface.publisheddeal.html#status","classes":"tsd-kind-property tsd-parent-kind-interface","parent":"lib/interface.PublishedDeal"},{"id":63,"kind":1024,"name":"chainDealID","url":"interfaces/lib_interface.publisheddeal.html#chaindealid","classes":"tsd-kind-property tsd-parent-kind-interface","parent":"lib/interface.PublishedDeal"},{"id":64,"kind":1024,"name":"lastChanged","url":"interfaces/lib_interface.publisheddeal.html#lastchanged","classes":"tsd-kind-property tsd-parent-kind-interface tsd-is-inherited","parent":"lib/interface.PublishedDeal"},{"id":65,"kind":1024,"name":"miner","url":"interfaces/lib_interface.publisheddeal.html#miner","classes":"tsd-kind-property tsd-parent-kind-interface tsd-is-inherited","parent":"lib/interface.PublishedDeal"},{"id":66,"kind":1024,"name":"network","url":"interfaces/lib_interface.publisheddeal.html#network","classes":"tsd-kind-property tsd-parent-kind-interface tsd-is-inherited","parent":"lib/interface.PublishedDeal"},{"id":67,"kind":1024,"name":"pieceCid","url":"interfaces/lib_interface.publisheddeal.html#piececid","classes":"tsd-kind-property tsd-parent-kind-interface tsd-is-inherited","parent":"lib/interface.PublishedDeal"},{"id":68,"kind":1024,"name":"batchRootCid","url":"interfaces/lib_interface.publisheddeal.html#batchrootcid","classes":"tsd-kind-property tsd-parent-kind-interface tsd-is-inherited","parent":"lib/interface.PublishedDeal"},{"id":69,"kind":256,"name":"FinalizedDeal","url":"interfaces/lib_interface.finalizeddeal.html","classes":"tsd-kind-interface tsd-parent-kind-module","parent":"lib/interface"},{"id":70,"kind":1024,"name":"status","url":"interfaces/lib_interface.finalizeddeal.html#status","classes":"tsd-kind-property tsd-parent-kind-interface","parent":"lib/interface.FinalizedDeal"},{"id":71,"kind":1024,"name":"chainDealID","url":"interfaces/lib_interface.finalizeddeal.html#chaindealid","classes":"tsd-kind-property tsd-parent-kind-interface","parent":"lib/interface.FinalizedDeal"},{"id":72,"kind":1024,"name":"datamodelSelector","url":"interfaces/lib_interface.finalizeddeal.html#datamodelselector","classes":"tsd-kind-property tsd-parent-kind-interface","parent":"lib/interface.FinalizedDeal"},{"id":73,"kind":1024,"name":"dealActivation","url":"interfaces/lib_interface.finalizeddeal.html#dealactivation","classes":"tsd-kind-property tsd-parent-kind-interface","parent":"lib/interface.FinalizedDeal"},{"id":74,"kind":1024,"name":"dealExpiration","url":"interfaces/lib_interface.finalizeddeal.html#dealexpiration","classes":"tsd-kind-property tsd-parent-kind-interface","parent":"lib/interface.FinalizedDeal"},{"id":75,"kind":1024,"name":"lastChanged","url":"interfaces/lib_interface.finalizeddeal.html#lastchanged","classes":"tsd-kind-property tsd-parent-kind-interface tsd-is-inherited","parent":"lib/interface.FinalizedDeal"},{"id":76,"kind":1024,"name":"miner","url":"interfaces/lib_interface.finalizeddeal.html#miner","classes":"tsd-kind-property tsd-parent-kind-interface tsd-is-inherited","parent":"lib/interface.FinalizedDeal"},{"id":77,"kind":1024,"name":"network","url":"interfaces/lib_interface.finalizeddeal.html#network","classes":"tsd-kind-property tsd-parent-kind-interface tsd-is-inherited","parent":"lib/interface.FinalizedDeal"},{"id":78,"kind":1024,"name":"pieceCid","url":"interfaces/lib_interface.finalizeddeal.html#piececid","classes":"tsd-kind-property tsd-parent-kind-interface tsd-is-inherited","parent":"lib/interface.FinalizedDeal"},{"id":79,"kind":1024,"name":"batchRootCid","url":"interfaces/lib_interface.finalizeddeal.html#batchrootcid","classes":"tsd-kind-property tsd-parent-kind-interface tsd-is-inherited","parent":"lib/interface.FinalizedDeal"},{"id":80,"kind":256,"name":"Pin","url":"interfaces/lib_interface.pin.html","classes":"tsd-kind-interface tsd-parent-kind-module","parent":"lib/interface"},{"id":81,"kind":1024,"name":"cid","url":"interfaces/lib_interface.pin.html#cid","classes":"tsd-kind-property tsd-parent-kind-interface","parent":"lib/interface.Pin"},{"id":82,"kind":1024,"name":"name","url":"interfaces/lib_interface.pin.html#name","classes":"tsd-kind-property tsd-parent-kind-interface","parent":"lib/interface.Pin"},{"id":83,"kind":1024,"name":"status","url":"interfaces/lib_interface.pin.html#status","classes":"tsd-kind-property tsd-parent-kind-interface","parent":"lib/interface.Pin"},{"id":84,"kind":1024,"name":"created","url":"interfaces/lib_interface.pin.html#created","classes":"tsd-kind-property tsd-parent-kind-interface","parent":"lib/interface.Pin"},{"id":85,"kind":4194304,"name":"PinStatus","url":"modules/lib_interface.html#pinstatus","classes":"tsd-kind-type-alias tsd-parent-kind-module","parent":"lib/interface"},{"id":86,"kind":256,"name":"TokenInput","url":"interfaces/lib_interface.tokeninput.html","classes":"tsd-kind-interface tsd-parent-kind-module","parent":"lib/interface"},{"id":87,"kind":1024,"name":"name","url":"interfaces/lib_interface.tokeninput.html#name","classes":"tsd-kind-property tsd-parent-kind-interface","parent":"lib/interface.TokenInput"},{"id":88,"kind":1024,"name":"description","url":"interfaces/lib_interface.tokeninput.html#description","classes":"tsd-kind-property tsd-parent-kind-interface","parent":"lib/interface.TokenInput"},{"id":89,"kind":1024,"name":"image","url":"interfaces/lib_interface.tokeninput.html#image","classes":"tsd-kind-property tsd-parent-kind-interface","parent":"lib/interface.TokenInput"},{"id":90,"kind":1024,"name":"decimals","url":"interfaces/lib_interface.tokeninput.html#decimals","classes":"tsd-kind-property tsd-parent-kind-interface","parent":"lib/interface.TokenInput"},{"id":91,"kind":1024,"name":"properties","url":"interfaces/lib_interface.tokeninput.html#properties","classes":"tsd-kind-property tsd-parent-kind-interface","parent":"lib/interface.TokenInput"},{"id":92,"kind":1024,"name":"localization","url":"interfaces/lib_interface.tokeninput.html#localization","classes":"tsd-kind-property tsd-parent-kind-interface","parent":"lib/interface.TokenInput"},{"id":93,"kind":256,"name":"Token","url":"interfaces/lib_interface.token.html","classes":"tsd-kind-interface tsd-parent-kind-module tsd-has-type-parameter","parent":"lib/interface"},{"id":94,"kind":1024,"name":"ipnft","url":"interfaces/lib_interface.token.html#ipnft","classes":"tsd-kind-property tsd-parent-kind-interface","parent":"lib/interface.Token"},{"id":95,"kind":1024,"name":"url","url":"interfaces/lib_interface.token.html#url","classes":"tsd-kind-property tsd-parent-kind-interface","parent":"lib/interface.Token"},{"id":96,"kind":1024,"name":"data","url":"interfaces/lib_interface.token.html#data","classes":"tsd-kind-property tsd-parent-kind-interface","parent":"lib/interface.Token"},{"id":97,"kind":2048,"name":"embed","url":"interfaces/lib_interface.token.html#embed","classes":"tsd-kind-method tsd-parent-kind-interface","parent":"lib/interface.Token"},{"id":98,"kind":4194304,"name":"EncodedError","url":"modules/lib_interface.html#encodederror","classes":"tsd-kind-type-alias tsd-parent-kind-module","parent":"lib/interface"},{"id":99,"kind":65536,"name":"__type","url":"modules/lib_interface.html#encodederror.__type","classes":"tsd-kind-type-literal tsd-parent-kind-type-alias","parent":"lib/interface.EncodedError"},{"id":100,"kind":1024,"name":"message","url":"modules/lib_interface.html#encodederror.__type.message","classes":"tsd-kind-property tsd-parent-kind-type-literal","parent":"lib/interface.EncodedError.__type"},{"id":101,"kind":4194304,"name":"EncodedURL","url":"modules/lib_interface.html#encodedurl","classes":"tsd-kind-type-alias tsd-parent-kind-module","parent":"lib/interface"},{"id":102,"kind":4194304,"name":"Result","url":"modules/lib_interface.html#result","classes":"tsd-kind-type-alias tsd-parent-kind-module tsd-has-type-parameter","parent":"lib/interface"},{"id":103,"kind":256,"name":"EncodedToken","url":"interfaces/lib_interface.encodedtoken.html","classes":"tsd-kind-interface tsd-parent-kind-module tsd-has-type-parameter","parent":"lib/interface"},{"id":104,"kind":1024,"name":"ipnft","url":"interfaces/lib_interface.encodedtoken.html#ipnft","classes":"tsd-kind-property tsd-parent-kind-interface","parent":"lib/interface.EncodedToken"},{"id":105,"kind":1024,"name":"url","url":"interfaces/lib_interface.encodedtoken.html#url","classes":"tsd-kind-property tsd-parent-kind-interface","parent":"lib/interface.EncodedToken"},{"id":106,"kind":1024,"name":"data","url":"interfaces/lib_interface.encodedtoken.html#data","classes":"tsd-kind-property tsd-parent-kind-interface","parent":"lib/interface.EncodedToken"},{"id":107,"kind":4194304,"name":"StoreResponse","url":"modules/lib_interface.html#storeresponse","classes":"tsd-kind-type-alias tsd-parent-kind-module tsd-has-type-parameter","parent":"lib/interface"},{"id":108,"kind":4194304,"name":"Encoded","url":"modules/lib_interface.html#encoded","classes":"tsd-kind-type-alias tsd-parent-kind-module tsd-has-type-parameter","parent":"lib/interface"},{"id":109,"kind":4194304,"name":"MatchRecord","url":"modules/lib_interface.html#matchrecord","classes":"tsd-kind-type-alias tsd-parent-kind-module tsd-has-type-parameter","parent":"lib/interface"},{"id":110,"kind":1,"name":"lib","url":"modules/lib.html","classes":"tsd-kind-module"},{"id":111,"kind":32,"name":"Token","url":"modules/lib.html#token","classes":"tsd-kind-variable tsd-parent-kind-module","parent":"lib"},{"id":112,"kind":128,"name":"NFTStorage","url":"classes/lib.nftstorage.html","classes":"tsd-kind-class tsd-parent-kind-module","parent":"lib"},{"id":113,"kind":2048,"name":"storeBlob","url":"classes/lib.nftstorage.html#storeblob-1","classes":"tsd-kind-method tsd-parent-kind-class tsd-is-static","parent":"lib.NFTStorage"},{"id":114,"kind":2048,"name":"storeCar","url":"classes/lib.nftstorage.html#storecar-1","classes":"tsd-kind-method tsd-parent-kind-class tsd-is-static","parent":"lib.NFTStorage"},{"id":115,"kind":2048,"name":"storeDirectory","url":"classes/lib.nftstorage.html#storedirectory-1","classes":"tsd-kind-method tsd-parent-kind-class tsd-is-static","parent":"lib.NFTStorage"},{"id":116,"kind":2048,"name":"store","url":"classes/lib.nftstorage.html#store-1","classes":"tsd-kind-method tsd-parent-kind-class tsd-has-type-parameter tsd-is-static","parent":"lib.NFTStorage"},{"id":117,"kind":2048,"name":"status","url":"classes/lib.nftstorage.html#status-1","classes":"tsd-kind-method tsd-parent-kind-class tsd-is-static","parent":"lib.NFTStorage"},{"id":118,"kind":2048,"name":"check","url":"classes/lib.nftstorage.html#check-1","classes":"tsd-kind-method tsd-parent-kind-class tsd-is-static","parent":"lib.NFTStorage"},{"id":119,"kind":2048,"name":"delete","url":"classes/lib.nftstorage.html#delete-1","classes":"tsd-kind-method tsd-parent-kind-class tsd-is-static","parent":"lib.NFTStorage"},{"id":120,"kind":512,"name":"constructor","url":"classes/lib.nftstorage.html#constructor","classes":"tsd-kind-constructor tsd-parent-kind-class","parent":"lib.NFTStorage"},{"id":121,"kind":1024,"name":"token","url":"classes/lib.nftstorage.html#token","classes":"tsd-kind-property tsd-parent-kind-class","parent":"lib.NFTStorage"},{"id":122,"kind":1024,"name":"endpoint","url":"classes/lib.nftstorage.html#endpoint","classes":"tsd-kind-property tsd-parent-kind-class","parent":"lib.NFTStorage"},{"id":123,"kind":2048,"name":"storeBlob","url":"classes/lib.nftstorage.html#storeblob","classes":"tsd-kind-method tsd-parent-kind-class","parent":"lib.NFTStorage"},{"id":124,"kind":2048,"name":"storeCar","url":"classes/lib.nftstorage.html#storecar","classes":"tsd-kind-method tsd-parent-kind-class","parent":"lib.NFTStorage"},{"id":125,"kind":2048,"name":"storeDirectory","url":"classes/lib.nftstorage.html#storedirectory","classes":"tsd-kind-method tsd-parent-kind-class","parent":"lib.NFTStorage"},{"id":126,"kind":2048,"name":"status","url":"classes/lib.nftstorage.html#status","classes":"tsd-kind-method tsd-parent-kind-class","parent":"lib.NFTStorage"},{"id":127,"kind":2048,"name":"delete","url":"classes/lib.nftstorage.html#delete","classes":"tsd-kind-method tsd-parent-kind-class","parent":"lib.NFTStorage"},{"id":128,"kind":2048,"name":"check","url":"classes/lib.nftstorage.html#check","classes":"tsd-kind-method tsd-parent-kind-class","parent":"lib.NFTStorage"},{"id":129,"kind":2048,"name":"store","url":"classes/lib.nftstorage.html#store","classes":"tsd-kind-method tsd-parent-kind-class tsd-has-type-parameter","parent":"lib.NFTStorage"},{"id":130,"kind":1,"name":"platform","url":"modules/platform.html","classes":"tsd-kind-module"},{"id":131,"kind":64,"name":"fetch","url":"modules/platform.html#fetch","classes":"tsd-kind-function tsd-parent-kind-module","parent":"platform"},{"id":132,"kind":32,"name":"FormData","url":"modules/platform.html#formdata","classes":"tsd-kind-variable tsd-parent-kind-module","parent":"platform"},{"id":133,"kind":65536,"name":"__type","url":"modules/platform.html#formdata.__type-2","classes":"tsd-kind-type-literal tsd-parent-kind-variable","parent":"platform.FormData"},{"id":134,"kind":32,"name":"Headers","url":"modules/platform.html#headers","classes":"tsd-kind-variable tsd-parent-kind-module","parent":"platform"},{"id":135,"kind":65536,"name":"__type","url":"modules/platform.html#headers.__type-3","classes":"tsd-kind-type-literal tsd-parent-kind-variable","parent":"platform.Headers"},{"id":136,"kind":32,"name":"Request","url":"modules/platform.html#request","classes":"tsd-kind-variable tsd-parent-kind-module","parent":"platform"},{"id":137,"kind":65536,"name":"__type","url":"modules/platform.html#request.__type-5","classes":"tsd-kind-type-literal tsd-parent-kind-variable","parent":"platform.Request"},{"id":138,"kind":32,"name":"Response","url":"modules/platform.html#response","classes":"tsd-kind-variable tsd-parent-kind-module","parent":"platform"},{"id":139,"kind":65536,"name":"__type","url":"modules/platform.html#response.__type-6","classes":"tsd-kind-type-literal tsd-parent-kind-variable","parent":"platform.Response"},{"id":140,"kind":32,"name":"Blob","url":"modules/platform.html#blob","classes":"tsd-kind-variable tsd-parent-kind-module","parent":"platform"},{"id":141,"kind":65536,"name":"__type","url":"modules/platform.html#blob.__type","classes":"tsd-kind-type-literal tsd-parent-kind-variable","parent":"platform.Blob"},{"id":142,"kind":32,"name":"File","url":"modules/platform.html#file","classes":"tsd-kind-variable tsd-parent-kind-module","parent":"platform"},{"id":143,"kind":65536,"name":"__type","url":"modules/platform.html#file.__type-1","classes":"tsd-kind-type-literal tsd-parent-kind-variable","parent":"platform.File"},{"id":144,"kind":32,"name":"ReadableStream","url":"modules/platform.html#readablestream","classes":"tsd-kind-variable tsd-parent-kind-module","parent":"platform"},{"id":145,"kind":65536,"name":"__type","url":"modules/platform.html#readablestream.__type-4","classes":"tsd-kind-type-literal tsd-parent-kind-variable","parent":"platform.ReadableStream"},{"id":146,"kind":1,"name":"platform.web","url":"modules/platform_web.html","classes":"tsd-kind-module"},{"id":147,"kind":64,"name":"fetch","url":"modules/platform_web.html#fetch","classes":"tsd-kind-function tsd-parent-kind-module","parent":"platform.web"},{"id":148,"kind":32,"name":"FormData","url":"modules/platform_web.html#formdata","classes":"tsd-kind-variable tsd-parent-kind-module","parent":"platform.web"},{"id":149,"kind":65536,"name":"__type","url":"modules/platform_web.html#formdata.__type-2","classes":"tsd-kind-type-literal tsd-parent-kind-variable","parent":"platform.web.FormData"},{"id":150,"kind":32,"name":"Headers","url":"modules/platform_web.html#headers","classes":"tsd-kind-variable tsd-parent-kind-module","parent":"platform.web"},{"id":151,"kind":65536,"name":"__type","url":"modules/platform_web.html#headers.__type-3","classes":"tsd-kind-type-literal tsd-parent-kind-variable","parent":"platform.web.Headers"},{"id":152,"kind":32,"name":"Request","url":"modules/platform_web.html#request","classes":"tsd-kind-variable tsd-parent-kind-module","parent":"platform.web"},{"id":153,"kind":65536,"name":"__type","url":"modules/platform_web.html#request.__type-5","classes":"tsd-kind-type-literal tsd-parent-kind-variable","parent":"platform.web.Request"},{"id":154,"kind":32,"name":"Response","url":"modules/platform_web.html#response","classes":"tsd-kind-variable tsd-parent-kind-module","parent":"platform.web"},{"id":155,"kind":65536,"name":"__type","url":"modules/platform_web.html#response.__type-6","classes":"tsd-kind-type-literal tsd-parent-kind-variable","parent":"platform.web.Response"},{"id":156,"kind":32,"name":"Blob","url":"modules/platform_web.html#blob","classes":"tsd-kind-variable tsd-parent-kind-module","parent":"platform.web"},{"id":157,"kind":65536,"name":"__type","url":"modules/platform_web.html#blob.__type","classes":"tsd-kind-type-literal tsd-parent-kind-variable","parent":"platform.web.Blob"},{"id":158,"kind":32,"name":"File","url":"modules/platform_web.html#file","classes":"tsd-kind-variable tsd-parent-kind-module","parent":"platform.web"},{"id":159,"kind":65536,"name":"__type","url":"modules/platform_web.html#file.__type-1","classes":"tsd-kind-type-literal tsd-parent-kind-variable","parent":"platform.web.File"},{"id":160,"kind":32,"name":"ReadableStream","url":"modules/platform_web.html#readablestream","classes":"tsd-kind-variable tsd-parent-kind-module","parent":"platform.web"},{"id":161,"kind":65536,"name":"__type","url":"modules/platform_web.html#readablestream.__type-4","classes":"tsd-kind-type-literal tsd-parent-kind-variable","parent":"platform.web.ReadableStream"},{"id":162,"kind":1,"name":"token","url":"modules/token.html","classes":"tsd-kind-module"},{"id":163,"kind":128,"name":"Token","url":"classes/token.token-1.html","classes":"tsd-kind-class tsd-parent-kind-module tsd-has-type-parameter","parent":"token"},{"id":164,"kind":2048,"name":"embed","url":"classes/token.token-1.html#embed-1","classes":"tsd-kind-method tsd-parent-kind-class tsd-has-type-parameter tsd-is-static","parent":"token.Token"},{"id":165,"kind":512,"name":"constructor","url":"classes/token.token-1.html#constructor","classes":"tsd-kind-constructor tsd-parent-kind-class tsd-has-type-parameter","parent":"token.Token"},{"id":166,"kind":1024,"name":"ipnft","url":"classes/token.token-1.html#ipnft","classes":"tsd-kind-property tsd-parent-kind-class","parent":"token.Token"},{"id":167,"kind":1024,"name":"url","url":"classes/token.token-1.html#url","classes":"tsd-kind-property tsd-parent-kind-class","parent":"token.Token"},{"id":168,"kind":1024,"name":"data","url":"classes/token.token-1.html#data","classes":"tsd-kind-property tsd-parent-kind-class","parent":"token.Token"},{"id":169,"kind":2048,"name":"embed","url":"classes/token.token-1.html#embed","classes":"tsd-kind-method tsd-parent-kind-class","parent":"token.Token"},{"id":170,"kind":64,"name":"embed","url":"modules/token.html#embed","classes":"tsd-kind-function tsd-parent-kind-module tsd-has-type-parameter","parent":"token"},{"id":171,"kind":64,"name":"decode","url":"modules/token.html#decode","classes":"tsd-kind-function tsd-parent-kind-module tsd-has-type-parameter","parent":"token"},{"id":172,"kind":64,"name":"encode","url":"modules/token.html#encode","classes":"tsd-kind-function tsd-parent-kind-module tsd-has-type-parameter","parent":"token"},{"id":173,"kind":64,"name":"mapWith","url":"modules/token.html#mapwith","classes":"tsd-kind-function tsd-parent-kind-module tsd-has-type-parameter","parent":"token"},{"id":174,"kind":4194304,"name":"EmbedOptions","url":"modules/token.html#embedoptions","classes":"tsd-kind-type-alias tsd-parent-kind-module tsd-has-type-parameter","parent":"token"},{"id":175,"kind":16777216,"name":"File","url":"modules/lib.html#file","classes":"tsd-kind-reference tsd-parent-kind-module","parent":"lib"},{"id":176,"kind":16777216,"name":"Blob","url":"modules/lib.html#blob","classes":"tsd-kind-reference tsd-parent-kind-module","parent":"lib"},{"id":177,"kind":16777216,"name":"FormData","url":"modules/lib.html#formdata","classes":"tsd-kind-reference tsd-parent-kind-module","parent":"lib"},{"id":178,"kind":16777216,"name":"toGatewayURL","url":"modules/lib.html#togatewayurl","classes":"tsd-kind-reference tsd-parent-kind-module","parent":"lib"}],"index":{"version":"2.3.9","fields":["name","parent"],"fieldVectors":[["name/0",[0,31.781]],["parent/0",[]],["name/1",[0,31.781]],["parent/1",[0,3.134]],["name/2",[1,42.767]],["parent/2",[0,3.134]],["name/3",[2,47.875]],["parent/3",[0,3.134]],["name/4",[3,47.875]],["parent/4",[0,3.134]],["name/5",[4,23.308]],["parent/5",[5,4.721]],["name/6",[0,31.781]],["parent/6",[6,4.721]],["name/7",[7,18.788]],["parent/7",[]],["name/8",[8,47.875]],["parent/8",[7,1.852]],["name/9",[9,47.875]],["parent/9",[7,1.852]],["name/10",[10,47.875]],["parent/10",[7,1.852]],["name/11",[11,39.402]],["parent/11",[12,4.217]],["name/12",[13,26.672]],["parent/12",[12,4.217]],["name/13",[14,47.875]],["parent/13",[7,1.852]],["name/14",[11,39.402]],["parent/14",[15,4.721]],["name/15",[16,47.875]],["parent/15",[7,1.852]],["name/16",[17,47.875]],["parent/16",[7,1.852]],["name/17",[18,39.402]],["parent/17",[19,3.134]],["name/18",[20,39.402]],["parent/18",[19,3.134]],["name/19",[21,39.402]],["parent/19",[19,3.134]],["name/20",[22,39.402]],["parent/20",[19,3.134]],["name/21",[23,28.416]],["parent/21",[19,3.134]],["name/22",[24,39.402]],["parent/22",[19,3.134]],["name/23",[25,39.402]],["parent/23",[19,3.134]],["name/24",[26,47.875]],["parent/24",[7,1.852]],["name/25",[27,39.402]],["parent/25",[28,3.637]],["name/26",[29,39.402]],["parent/26",[28,3.637]],["name/27",[4,23.308]],["parent/27",[28,3.637]],["name/28",[23,28.416]],["parent/28",[30,4.721]],["name/29",[31,42.767]],["parent/29",[28,3.637]],["name/30",[32,47.875]],["parent/30",[7,1.852]],["name/31",[27,39.402]],["parent/31",[33,3.439]],["name/32",[34,47.875]],["parent/32",[33,3.439]],["name/33",[31,42.767]],["parent/33",[33,3.439]],["name/34",[29,39.402]],["parent/34",[33,3.439]],["name/35",[35,42.767]],["parent/35",[33,3.439]],["name/36",[36,47.875]],["parent/36",[7,1.852]],["name/37",[37,47.875]],["parent/37",[7,1.852]],["name/38",[38,33.212]],["parent/38",[39,3.439]],["name/39",[40,34.882]],["parent/39",[39,3.439]],["name/40",[41,34.882]],["parent/40",[39,3.439]],["name/41",[42,34.882]],["parent/41",[39,3.439]],["name/42",[43,34.882]],["parent/42",[39,3.439]],["name/43",[44,47.875]],["parent/43",[7,1.852]],["name/44",[23,28.416]],["parent/44",[45,4.217]],["name/45",[38,33.212]],["parent/45",[45,4.217]],["name/46",[46,47.875]],["parent/46",[7,1.852]],["name/47",[23,28.416]],["parent/47",[47,3.275]],["name/48",[38,33.212]],["parent/48",[47,3.275]],["name/49",[40,34.882]],["parent/49",[47,3.275]],["name/50",[41,34.882]],["parent/50",[47,3.275]],["name/51",[42,34.882]],["parent/51",[47,3.275]],["name/52",[43,34.882]],["parent/52",[47,3.275]],["name/53",[48,47.875]],["parent/53",[7,1.852]],["name/54",[23,28.416]],["parent/54",[49,3.134]],["name/55",[50,47.875]],["parent/55",[49,3.134]],["name/56",[38,33.212]],["parent/56",[49,3.134]],["name/57",[40,34.882]],["parent/57",[49,3.134]],["name/58",[41,34.882]],["parent/58",[49,3.134]],["name/59",[42,34.882]],["parent/59",[49,3.134]],["name/60",[43,34.882]],["parent/60",[49,3.134]],["name/61",[51,47.875]],["parent/61",[7,1.852]],["name/62",[23,28.416]],["parent/62",[52,3.134]],["name/63",[53,42.767]],["parent/63",[52,3.134]],["name/64",[38,33.212]],["parent/64",[52,3.134]],["name/65",[40,34.882]],["parent/65",[52,3.134]],["name/66",[41,34.882]],["parent/66",[52,3.134]],["name/67",[42,34.882]],["parent/67",[52,3.134]],["name/68",[43,34.882]],["parent/68",[52,3.134]],["name/69",[54,47.875]],["parent/69",[7,1.852]],["name/70",[23,28.416]],["parent/70",[55,2.802]],["name/71",[53,42.767]],["parent/71",[55,2.802]],["name/72",[56,47.875]],["parent/72",[55,2.802]],["name/73",[57,47.875]],["parent/73",[55,2.802]],["name/74",[58,47.875]],["parent/74",[55,2.802]],["name/75",[38,33.212]],["parent/75",[55,2.802]],["name/76",[40,34.882]],["parent/76",[55,2.802]],["name/77",[41,34.882]],["parent/77",[55,2.802]],["name/78",[42,34.882]],["parent/78",[55,2.802]],["name/79",[43,34.882]],["parent/79",[55,2.802]],["name/80",[29,39.402]],["parent/80",[7,1.852]],["name/81",[27,39.402]],["parent/81",[59,3.637]],["name/82",[60,42.767]],["parent/82",[59,3.637]],["name/83",[23,28.416]],["parent/83",[59,3.637]],["name/84",[35,42.767]],["parent/84",[59,3.637]],["name/85",[61,47.875]],["parent/85",[7,1.852]],["name/86",[62,47.875]],["parent/86",[7,1.852]],["name/87",[60,42.767]],["parent/87",[63,3.275]],["name/88",[64,47.875]],["parent/88",[63,3.275]],["name/89",[65,47.875]],["parent/89",[63,3.275]],["name/90",[66,47.875]],["parent/90",[63,3.275]],["name/91",[67,47.875]],["parent/91",[63,3.275]],["name/92",[68,47.875]],["parent/92",[63,3.275]],["name/93",[13,26.672]],["parent/93",[7,1.852]],["name/94",[69,39.402]],["parent/94",[70,3.637]],["name/95",[71,39.402]],["parent/95",[70,3.637]],["name/96",[72,39.402]],["parent/96",[70,3.637]],["name/97",[73,36.889]],["parent/97",[70,3.637]],["name/98",[74,47.875]],["parent/98",[7,1.852]],["name/99",[4,23.308]],["parent/99",[75,4.721]],["name/100",[76,47.875]],["parent/100",[77,4.721]],["name/101",[78,47.875]],["parent/101",[7,1.852]],["name/102",[79,47.875]],["parent/102",[7,1.852]],["name/103",[80,47.875]],["parent/103",[7,1.852]],["name/104",[69,39.402]],["parent/104",[81,3.885]],["name/105",[71,39.402]],["parent/105",[81,3.885]],["name/106",[72,39.402]],["parent/106",[81,3.885]],["name/107",[82,47.875]],["parent/107",[7,1.852]],["name/108",[83,47.875]],["parent/108",[7,1.852]],["name/109",[84,47.875]],["parent/109",[7,1.852]],["name/110",[85,31.781]],["parent/110",[]],["name/111",[13,26.672]],["parent/111",[85,3.134]],["name/112",[86,47.875]],["parent/112",[85,3.134]],["name/113",[20,39.402]],["parent/113",[87,2.298]],["name/114",[21,39.402]],["parent/114",[87,2.298]],["name/115",[22,39.402]],["parent/115",[87,2.298]],["name/116",[18,39.402]],["parent/116",[87,2.298]],["name/117",[23,28.416]],["parent/117",[87,2.298]],["name/118",[25,39.402]],["parent/118",[87,2.298]],["name/119",[24,39.402]],["parent/119",[87,2.298]],["name/120",[88,42.767]],["parent/120",[87,2.298]],["name/121",[13,26.672]],["parent/121",[87,2.298]],["name/122",[11,39.402]],["parent/122",[87,2.298]],["name/123",[20,39.402]],["parent/123",[87,2.298]],["name/124",[21,39.402]],["parent/124",[87,2.298]],["name/125",[22,39.402]],["parent/125",[87,2.298]],["name/126",[23,28.416]],["parent/126",[87,2.298]],["name/127",[24,39.402]],["parent/127",[87,2.298]],["name/128",[25,39.402]],["parent/128",[87,2.298]],["name/129",[18,39.402]],["parent/129",[87,2.298]],["name/130",[89,29.417]],["parent/130",[]],["name/131",[90,42.767]],["parent/131",[89,2.901]],["name/132",[91,39.402]],["parent/132",[89,2.901]],["name/133",[4,23.308]],["parent/133",[92,4.721]],["name/134",[93,42.767]],["parent/134",[89,2.901]],["name/135",[4,23.308]],["parent/135",[94,4.721]],["name/136",[95,42.767]],["parent/136",[89,2.901]],["name/137",[4,23.308]],["parent/137",[96,4.721]],["name/138",[97,42.767]],["parent/138",[89,2.901]],["name/139",[4,23.308]],["parent/139",[98,4.721]],["name/140",[99,39.402]],["parent/140",[89,2.901]],["name/141",[4,23.308]],["parent/141",[100,4.721]],["name/142",[101,39.402]],["parent/142",[89,2.901]],["name/143",[4,23.308]],["parent/143",[102,4.721]],["name/144",[103,42.767]],["parent/144",[89,2.901]],["name/145",[4,23.308]],["parent/145",[104,4.721]],["name/146",[105,29.417]],["parent/146",[]],["name/147",[90,42.767]],["parent/147",[105,2.901]],["name/148",[91,39.402]],["parent/148",[105,2.901]],["name/149",[4,23.308]],["parent/149",[106,4.721]],["name/150",[93,42.767]],["parent/150",[105,2.901]],["name/151",[4,23.308]],["parent/151",[107,4.721]],["name/152",[95,42.767]],["parent/152",[105,2.901]],["name/153",[4,23.308]],["parent/153",[108,4.721]],["name/154",[97,42.767]],["parent/154",[105,2.901]],["name/155",[4,23.308]],["parent/155",[109,4.721]],["name/156",[99,39.402]],["parent/156",[105,2.901]],["name/157",[4,23.308]],["parent/157",[110,4.721]],["name/158",[101,39.402]],["parent/158",[105,2.901]],["name/159",[4,23.308]],["parent/159",[111,4.721]],["name/160",[103,42.767]],["parent/160",[105,2.901]],["name/161",[4,23.308]],["parent/161",[112,4.721]],["name/162",[13,26.672]],["parent/162",[]],["name/163",[13,26.672]],["parent/163",[13,2.63]],["name/164",[73,36.889]],["parent/164",[113,3.275]],["name/165",[88,42.767]],["parent/165",[113,3.275]],["name/166",[69,39.402]],["parent/166",[113,3.275]],["name/167",[71,39.402]],["parent/167",[113,3.275]],["name/168",[72,39.402]],["parent/168",[113,3.275]],["name/169",[73,36.889]],["parent/169",[113,3.275]],["name/170",[73,36.889]],["parent/170",[13,2.63]],["name/171",[114,47.875]],["parent/171",[13,2.63]],["name/172",[115,47.875]],["parent/172",[13,2.63]],["name/173",[116,47.875]],["parent/173",[13,2.63]],["name/174",[117,47.875]],["parent/174",[13,2.63]],["name/175",[101,39.402]],["parent/175",[85,3.134]],["name/176",[99,39.402]],["parent/176",[85,3.134]],["name/177",[91,39.402]],["parent/177",[85,3.134]],["name/178",[1,42.767]],["parent/178",[85,3.134]]],"invertedIndex":[["__type",{"_index":4,"name":{"5":{},"27":{},"99":{},"133":{},"135":{},"137":{},"139":{},"141":{},"143":{},"145":{},"149":{},"151":{},"153":{},"155":{},"157":{},"159":{},"161":{}},"parent":{}}],["api",{"_index":17,"name":{"16":{}},"parent":{}}],["batchrootcid",{"_index":43,"name":{"42":{},"52":{},"60":{},"68":{},"79":{}},"parent":{}}],["blob",{"_index":99,"name":{"140":{},"156":{},"176":{}},"parent":{}}],["carreader",{"_index":8,"name":{"8":{}},"parent":{}}],["chaindealid",{"_index":53,"name":{"63":{},"71":{}},"parent":{}}],["check",{"_index":25,"name":{"23":{},"118":{},"128":{}},"parent":{}}],["checkresult",{"_index":26,"name":{"24":{}},"parent":{}}],["cid",{"_index":27,"name":{"25":{},"31":{},"81":{}},"parent":{}}],["cidstring",{"_index":16,"name":{"15":{}},"parent":{}}],["constructor",{"_index":88,"name":{"120":{},"165":{}},"parent":{}}],["created",{"_index":35,"name":{"35":{},"84":{}},"parent":{}}],["data",{"_index":72,"name":{"96":{},"106":{},"168":{}},"parent":{}}],["datamodelselector",{"_index":56,"name":{"72":{}},"parent":{}}],["deal",{"_index":36,"name":{"36":{}},"parent":{}}],["dealactivation",{"_index":57,"name":{"73":{}},"parent":{}}],["dealexpiration",{"_index":58,"name":{"74":{}},"parent":{}}],["dealinfo",{"_index":37,"name":{"37":{}},"parent":{}}],["deals",{"_index":31,"name":{"29":{},"33":{}},"parent":{}}],["decimals",{"_index":66,"name":{"90":{}},"parent":{}}],["decode",{"_index":114,"name":{"171":{}},"parent":{}}],["delete",{"_index":24,"name":{"22":{},"119":{},"127":{}},"parent":{}}],["description",{"_index":64,"name":{"88":{}},"parent":{}}],["embed",{"_index":73,"name":{"97":{},"164":{},"169":{},"170":{}},"parent":{}}],["embedoptions",{"_index":117,"name":{"174":{}},"parent":{}}],["encode",{"_index":115,"name":{"172":{}},"parent":{}}],["encoded",{"_index":83,"name":{"108":{}},"parent":{}}],["encodederror",{"_index":74,"name":{"98":{}},"parent":{}}],["encodedtoken",{"_index":80,"name":{"103":{}},"parent":{}}],["encodedurl",{"_index":78,"name":{"101":{}},"parent":{}}],["endpoint",{"_index":11,"name":{"11":{},"14":{},"122":{}},"parent":{}}],["faileddeal",{"_index":48,"name":{"53":{}},"parent":{}}],["fetch",{"_index":90,"name":{"131":{},"147":{}},"parent":{}}],["file",{"_index":101,"name":{"142":{},"158":{},"175":{}},"parent":{}}],["finalizeddeal",{"_index":54,"name":{"69":{}},"parent":{}}],["formdata",{"_index":91,"name":{"132":{},"148":{},"177":{}},"parent":{}}],["gateway",{"_index":0,"name":{"0":{},"1":{},"6":{}},"parent":{"1":{},"2":{},"3":{},"4":{}}}],["gateway.gatewayurloptions",{"_index":5,"name":{},"parent":{"5":{}}}],["gateway.gatewayurloptions.__type",{"_index":6,"name":{},"parent":{"6":{}}}],["gatewayurl",{"_index":2,"name":{"3":{}},"parent":{}}],["gatewayurloptions",{"_index":3,"name":{"4":{}},"parent":{}}],["headers",{"_index":93,"name":{"134":{},"150":{}},"parent":{}}],["image",{"_index":65,"name":{"89":{}},"parent":{}}],["ipnft",{"_index":69,"name":{"94":{},"104":{},"166":{}},"parent":{}}],["lastchanged",{"_index":38,"name":{"38":{},"45":{},"48":{},"56":{},"64":{},"75":{}},"parent":{}}],["lib",{"_index":85,"name":{"110":{}},"parent":{"111":{},"112":{},"175":{},"176":{},"177":{},"178":{}}}],["lib.nftstorage",{"_index":87,"name":{},"parent":{"113":{},"114":{},"115":{},"116":{},"117":{},"118":{},"119":{},"120":{},"121":{},"122":{},"123":{},"124":{},"125":{},"126":{},"127":{},"128":{},"129":{}}}],["lib/interface",{"_index":7,"name":{"7":{}},"parent":{"8":{},"9":{},"10":{},"13":{},"15":{},"16":{},"24":{},"30":{},"36":{},"37":{},"43":{},"46":{},"53":{},"61":{},"69":{},"80":{},"85":{},"86":{},"93":{},"98":{},"101":{},"102":{},"103":{},"107":{},"108":{},"109":{}}}],["lib/interface.api",{"_index":19,"name":{},"parent":{"17":{},"18":{},"19":{},"20":{},"21":{},"22":{},"23":{}}}],["lib/interface.checkresult",{"_index":28,"name":{},"parent":{"25":{},"26":{},"27":{},"29":{}}}],["lib/interface.checkresult.__type",{"_index":30,"name":{},"parent":{"28":{}}}],["lib/interface.dealinfo",{"_index":39,"name":{},"parent":{"38":{},"39":{},"40":{},"41":{},"42":{}}}],["lib/interface.encodederror",{"_index":75,"name":{},"parent":{"99":{}}}],["lib/interface.encodederror.__type",{"_index":77,"name":{},"parent":{"100":{}}}],["lib/interface.encodedtoken",{"_index":81,"name":{},"parent":{"104":{},"105":{},"106":{}}}],["lib/interface.faileddeal",{"_index":49,"name":{},"parent":{"54":{},"55":{},"56":{},"57":{},"58":{},"59":{},"60":{}}}],["lib/interface.finalizeddeal",{"_index":55,"name":{},"parent":{"70":{},"71":{},"72":{},"73":{},"74":{},"75":{},"76":{},"77":{},"78":{},"79":{}}}],["lib/interface.pendingdeal",{"_index":47,"name":{},"parent":{"47":{},"48":{},"49":{},"50":{},"51":{},"52":{}}}],["lib/interface.pin",{"_index":59,"name":{},"parent":{"81":{},"82":{},"83":{},"84":{}}}],["lib/interface.publicservice",{"_index":15,"name":{},"parent":{"14":{}}}],["lib/interface.publisheddeal",{"_index":52,"name":{},"parent":{"62":{},"63":{},"64":{},"65":{},"66":{},"67":{},"68":{}}}],["lib/interface.queueddeal",{"_index":45,"name":{},"parent":{"44":{},"45":{}}}],["lib/interface.service",{"_index":12,"name":{},"parent":{"11":{},"12":{}}}],["lib/interface.statusresult",{"_index":33,"name":{},"parent":{"31":{},"32":{},"33":{},"34":{},"35":{}}}],["lib/interface.token",{"_index":70,"name":{},"parent":{"94":{},"95":{},"96":{},"97":{}}}],["lib/interface.tokeninput",{"_index":63,"name":{},"parent":{"87":{},"88":{},"89":{},"90":{},"91":{},"92":{}}}],["localization",{"_index":68,"name":{"92":{}},"parent":{}}],["mapwith",{"_index":116,"name":{"173":{}},"parent":{}}],["matchrecord",{"_index":84,"name":{"109":{}},"parent":{}}],["message",{"_index":76,"name":{"100":{}},"parent":{}}],["miner",{"_index":40,"name":{"39":{},"49":{},"57":{},"65":{},"76":{}},"parent":{}}],["name",{"_index":60,"name":{"82":{},"87":{}},"parent":{}}],["network",{"_index":41,"name":{"40":{},"50":{},"58":{},"66":{},"77":{}},"parent":{}}],["nftstorage",{"_index":86,"name":{"112":{}},"parent":{}}],["pendingdeal",{"_index":46,"name":{"46":{}},"parent":{}}],["piececid",{"_index":42,"name":{"41":{},"51":{},"59":{},"67":{},"78":{}},"parent":{}}],["pin",{"_index":29,"name":{"26":{},"34":{},"80":{}},"parent":{}}],["pinstatus",{"_index":61,"name":{"85":{}},"parent":{}}],["platform",{"_index":89,"name":{"130":{}},"parent":{"131":{},"132":{},"134":{},"136":{},"138":{},"140":{},"142":{},"144":{}}}],["platform.blob",{"_index":100,"name":{},"parent":{"141":{}}}],["platform.file",{"_index":102,"name":{},"parent":{"143":{}}}],["platform.formdata",{"_index":92,"name":{},"parent":{"133":{}}}],["platform.headers",{"_index":94,"name":{},"parent":{"135":{}}}],["platform.readablestream",{"_index":104,"name":{},"parent":{"145":{}}}],["platform.request",{"_index":96,"name":{},"parent":{"137":{}}}],["platform.response",{"_index":98,"name":{},"parent":{"139":{}}}],["platform.web",{"_index":105,"name":{"146":{}},"parent":{"147":{},"148":{},"150":{},"152":{},"154":{},"156":{},"158":{},"160":{}}}],["platform.web.blob",{"_index":110,"name":{},"parent":{"157":{}}}],["platform.web.file",{"_index":111,"name":{},"parent":{"159":{}}}],["platform.web.formdata",{"_index":106,"name":{},"parent":{"149":{}}}],["platform.web.headers",{"_index":107,"name":{},"parent":{"151":{}}}],["platform.web.readablestream",{"_index":112,"name":{},"parent":{"161":{}}}],["platform.web.request",{"_index":108,"name":{},"parent":{"153":{}}}],["platform.web.response",{"_index":109,"name":{},"parent":{"155":{}}}],["properties",{"_index":67,"name":{"91":{}},"parent":{}}],["publicservice",{"_index":14,"name":{"13":{}},"parent":{}}],["publisheddeal",{"_index":51,"name":{"61":{}},"parent":{}}],["queueddeal",{"_index":44,"name":{"43":{}},"parent":{}}],["readablestream",{"_index":103,"name":{"144":{},"160":{}},"parent":{}}],["request",{"_index":95,"name":{"136":{},"152":{}},"parent":{}}],["response",{"_index":97,"name":{"138":{},"154":{}},"parent":{}}],["result",{"_index":79,"name":{"102":{}},"parent":{}}],["service",{"_index":10,"name":{"10":{}},"parent":{}}],["size",{"_index":34,"name":{"32":{}},"parent":{}}],["status",{"_index":23,"name":{"21":{},"28":{},"44":{},"47":{},"54":{},"62":{},"70":{},"83":{},"117":{},"126":{}},"parent":{}}],["statusresult",{"_index":32,"name":{"30":{}},"parent":{}}],["statustext",{"_index":50,"name":{"55":{}},"parent":{}}],["store",{"_index":18,"name":{"17":{},"116":{},"129":{}},"parent":{}}],["storeblob",{"_index":20,"name":{"18":{},"113":{},"123":{}},"parent":{}}],["storecar",{"_index":21,"name":{"19":{},"114":{},"124":{}},"parent":{}}],["storedirectory",{"_index":22,"name":{"20":{},"115":{},"125":{}},"parent":{}}],["storeresponse",{"_index":82,"name":{"107":{}},"parent":{}}],["tagged",{"_index":9,"name":{"9":{}},"parent":{}}],["togatewayurl",{"_index":1,"name":{"2":{},"178":{}},"parent":{}}],["token",{"_index":13,"name":{"12":{},"93":{},"111":{},"121":{},"162":{},"163":{}},"parent":{"163":{},"170":{},"171":{},"172":{},"173":{},"174":{}}}],["token.token",{"_index":113,"name":{},"parent":{"164":{},"165":{},"166":{},"167":{},"168":{},"169":{}}}],["tokeninput",{"_index":62,"name":{"86":{}},"parent":{}}],["url",{"_index":71,"name":{"95":{},"105":{},"167":{}},"parent":{}}]],"pipeline":[]}}
49,906
49,906
0.658718
93a72fe5bf51222ceb10ee235752e4d69ff7928c
67,810
js
JavaScript
public/assets/cms/preview.js
tbkoo53/shirasagi-cms-heroku-button-ver1_5
b0903734cfa65d788ca100102c3b7e63f0d0496e
[ "MIT" ]
null
null
null
public/assets/cms/preview.js
tbkoo53/shirasagi-cms-heroku-button-ver1_5
b0903734cfa65d788ca100102c3b7e63f0d0496e
[ "MIT" ]
null
null
null
public/assets/cms/preview.js
tbkoo53/shirasagi-cms-heroku-button-ver1_5
b0903734cfa65d788ca100102c3b7e63f0d0496e
[ "MIT" ]
1
2017-08-16T09:22:00.000Z
2017-08-16T09:22:00.000Z
/*! * @copyright Copyright &copy; Kartik Visweswaran, Krajee.com, 2014 - 2015 * @version 1.3.3 * * Date formatter utility library that allows formatting date/time variables or Date objects using PHP DateTime format. * @see http://php.net/manual/en/function.date.php * * For more JQuery plugins visit http://plugins.krajee.com * For more Yii related demos visit http://demos.krajee.com */ var DateFormatter;!function(){"use strict";var t,e,o,i,r,n;r=864e5,n=3600,t=function(t,e){return"string"==typeof t&&"string"==typeof e&&t.toLowerCase()===e.toLowerCase()},e=function(t,o,i){var r=i||"0",n=t.toString();return n.length<o?e(r+n,o):n},o=function(t){var e,i;for(t=t||{},e=1;e<arguments.length;e++)if(i=arguments[e])for(var r in i)i.hasOwnProperty(r)&&("object"==typeof i[r]?o(t[r],i[r]):t[r]=i[r]);return t},i={dateSettings:{days:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],daysShort:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],months:["January","February","March","April","May","June","July","August","September","October","November","December"],monthsShort:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],meridiem:["AM","PM"],ordinal:function(t){var e=t%10,o={1:"st",2:"nd",3:"rd"};return 1!==Math.floor(t%100/10)&&o[e]?o[e]:"th"}},separators:/[ \-+\/\.T:@]/g,validParts:/[dDjlNSwzWFmMntLoYyaABgGhHisueTIOPZcrU]/g,intParts:/[djwNzmnyYhHgGis]/g,tzParts:/\b(?:[PMCEA][SDP]T|(?:Pacific|Mountain|Central|Eastern|Atlantic) (?:Standard|Daylight|Prevailing) Time|(?:GMT|UTC)(?:[-+]\d{4})?)\b/g,tzClip:/[^-+\dA-Z]/g},DateFormatter=function(t){var e=this,r=o(i,t);e.dateSettings=r.dateSettings,e.separators=r.separators,e.validParts=r.validParts,e.intParts=r.intParts,e.tzParts=r.tzParts,e.tzClip=r.tzClip},DateFormatter.prototype={constructor:DateFormatter,parseDate:function(e,o){var i,r,n,s,a,p,h,u,l,c,f=this,y=!1,d=!1,g=f.dateSettings,v={date:null,year:null,month:null,day:null,hour:0,min:0,sec:0};if(!e)return void 0;if(e instanceof Date)return e;if("number"==typeof e)return new Date(e);if("U"===o)return n=parseInt(e),n?new Date(1e3*n):e;if("string"!=typeof e)return"";if(i=o.match(f.validParts),!i||0===i.length)throw new Error("Invalid date format definition.");for(r=e.replace(f.separators,"\x00").split("\x00"),n=0;n<r.length;n++)switch(s=r[n],a=parseInt(s),i[n]){case"y":case"Y":l=s.length,2===l?v.year=parseInt((70>a?"20":"19")+s):4===l&&(v.year=a),y=!0;break;case"m":case"n":case"M":case"F":isNaN(s)?(p=g.monthsShort.indexOf(s),p>-1&&(v.month=p+1),p=g.months.indexOf(s),p>-1&&(v.month=p+1)):a>=1&&12>=a&&(v.month=a),y=!0;break;case"d":case"j":a>=1&&31>=a&&(v.day=a),y=!0;break;case"g":case"h":h=i.indexOf("a")>-1?i.indexOf("a"):i.indexOf("A")>-1?i.indexOf("A"):-1,c=r[h],h>-1?(u=t(c,g.meridiem[0])?0:t(c,g.meridiem[1])?12:-1,a>=1&&12>=a&&u>-1?v.hour=a+u:a>=0&&23>=a&&(v.hour=a)):a>=0&&23>=a&&(v.hour=a),d=!0;break;case"G":case"H":a>=0&&23>=a&&(v.hour=a),d=!0;break;case"i":a>=0&&59>=a&&(v.min=a),d=!0;break;case"s":a>=0&&59>=a&&(v.sec=a),d=!0}if(y===!0&&v.year&&v.month&&v.day)v.date=new Date(v.year,v.month-1,v.day,v.hour,v.min,v.sec,0);else{if(d!==!0)return!1;v.date=new Date(0,0,0,v.hour,v.min,v.sec,0)}return v.date},guessDate:function(t,e){if("string"!=typeof t)return t;var o,i,r,n,s=this,a=t.replace(s.separators,"\x00").split("\x00"),p=/^[djmn]/g,h=e.match(s.validParts),u=new Date,l=0;if(!p.test(h[0]))return t;for(i=0;i<a.length;i++){switch(l=2,r=a[i],n=parseInt(r.substr(0,2)),i){case 0:"m"===h[0]||"n"===h[0]?u.setMonth(n-1):u.setDate(n);break;case 1:"m"===h[0]||"n"===h[0]?u.setDate(n):u.setMonth(n-1);break;case 2:o=u.getFullYear(),r.length<4?(u.setFullYear(parseInt(o.toString().substr(0,4-r.length)+r)),l=r.length):(u.setFullYear=parseInt(r.substr(0,4)),l=4);break;case 3:u.setHours(n);break;case 4:u.setMinutes(n);break;case 5:u.setSeconds(n)}r.substr(l).length>0&&a.splice(i+1,0,r.substr(l))}return u},parseFormat:function(t,o){var i,s=this,a=s.dateSettings,p=/\\?(.?)/gi,h=function(t,e){return i[t]?i[t]():e};return i={d:function(){return e(i.j(),2)},D:function(){return a.daysShort[i.w()]},j:function(){return o.getDate()},l:function(){return a.days[i.w()]},N:function(){return i.w()||7},w:function(){return o.getDay()},z:function(){var t=new Date(i.Y(),i.n()-1,i.j()),e=new Date(i.Y(),0,1);return Math.round((t-e)/r)},W:function(){var t=new Date(i.Y(),i.n()-1,i.j()-i.N()+3),o=new Date(t.getFullYear(),0,4);return e(1+Math.round((t-o)/r/7),2)},F:function(){return a.months[o.getMonth()]},m:function(){return e(i.n(),2)},M:function(){return a.monthsShort[o.getMonth()]},n:function(){return o.getMonth()+1},t:function(){return new Date(i.Y(),i.n(),0).getDate()},L:function(){var t=i.Y();return t%4===0&&t%100!==0||t%400===0?1:0},o:function(){var t=i.n(),e=i.W(),o=i.Y();return o+(12===t&&9>e?1:1===t&&e>9?-1:0)},Y:function(){return o.getFullYear()},y:function(){return i.Y().toString().slice(-2)},a:function(){return i.A().toLowerCase()},A:function(){var t=i.G()<12?0:1;return a.meridiem[t]},B:function(){var t=o.getUTCHours()*n,i=60*o.getUTCMinutes(),r=o.getUTCSeconds();return e(Math.floor((t+i+r+n)/86.4)%1e3,3)},g:function(){return i.G()%12||12},G:function(){return o.getHours()},h:function(){return e(i.g(),2)},H:function(){return e(i.G(),2)},i:function(){return e(o.getMinutes(),2)},s:function(){return e(o.getSeconds(),2)},u:function(){return e(1e3*o.getMilliseconds(),6)},e:function(){var t=/\((.*)\)/.exec(String(o))[1];return t||"Coordinated Universal Time"},T:function(){var t=(String(o).match(s.tzParts)||[""]).pop().replace(s.tzClip,"");return t||"UTC"},I:function(){var t=new Date(i.Y(),0),e=Date.UTC(i.Y(),0),o=new Date(i.Y(),6),r=Date.UTC(i.Y(),6);return t-e!==o-r?1:0},O:function(){var t=o.getTimezoneOffset(),i=Math.abs(t);return(t>0?"-":"+")+e(100*Math.floor(i/60)+i%60,4)},P:function(){var t=i.O();return t.substr(0,3)+":"+t.substr(3,2)},Z:function(){return 60*-o.getTimezoneOffset()},c:function(){return"Y-m-d\\TH:i:sP".replace(p,h)},r:function(){return"D, d M Y H:i:s O".replace(p,h)},U:function(){return o.getTime()/1e3||0}},h(t,t)},formatDate:function(t,e){var o,i,r,n,s,a=this,p="";if("string"==typeof t&&(t=a.parseDate(t,e),t===!1))return!1;if(t instanceof Date){for(r=e.length,o=0;r>o;o++)s=e.charAt(o),"S"!==s&&(n=a.parseFormat(s,t),o!==r-1&&a.intParts.test(s)&&"S"===e.charAt(o+1)&&(i=parseInt(n),n+=a.dateSettings.ordinal(i)),p+=n);return p}return""}}}(),function(t){"function"==typeof define&&define.amd?define(["jquery","jquery-mousewheel"],t):"object"==typeof exports?module.exports=t:t(jQuery)}(function(t){"use strict";function e(t,e,o){this.date=t,this.desc=e,this.style=o}var o=!1,i={i18n:{ar:{months:["\u0643\u0627\u0646\u0648\u0646 \u0627\u0644\u062b\u0627\u0646\u064a","\u0634\u0628\u0627\u0637","\u0622\u0630\u0627\u0631","\u0646\u064a\u0633\u0627\u0646","\u0645\u0627\u064a\u0648","\u062d\u0632\u064a\u0631\u0627\u0646","\u062a\u0645\u0648\u0632","\u0622\u0628","\u0623\u064a\u0644\u0648\u0644","\u062a\u0634\u0631\u064a\u0646 \u0627\u0644\u0623\u0648\u0644","\u062a\u0634\u0631\u064a\u0646 \u0627\u0644\u062b\u0627\u0646\u064a","\u0643\u0627\u0646\u0648\u0646 \u0627\u0644\u0623\u0648\u0644"],dayOfWeekShort:["\u0646","\u062b","\u0639","\u062e","\u062c","\u0633","\u062d"],dayOfWeek:["\u0627\u0644\u0623\u062d\u062f","\u0627\u0644\u0627\u062b\u0646\u064a\u0646","\u0627\u0644\u062b\u0644\u0627\u062b\u0627\u0621","\u0627\u0644\u0623\u0631\u0628\u0639\u0627\u0621","\u0627\u0644\u062e\u0645\u064a\u0633","\u0627\u0644\u062c\u0645\u0639\u0629","\u0627\u0644\u0633\u0628\u062a","\u0627\u0644\u0623\u062d\u062f"]},ro:{months:["Ianuarie","Februarie","Martie","Aprilie","Mai","Iunie","Iulie","August","Septembrie","Octombrie","Noiembrie","Decembrie"],dayOfWeekShort:["Du","Lu","Ma","Mi","Jo","Vi","S\xe2"],dayOfWeek:["Duminic\u0103","Luni","Mar\u0163i","Miercuri","Joi","Vineri","S\xe2mb\u0103t\u0103"]},id:{months:["Januari","Februari","Maret","April","Mei","Juni","Juli","Agustus","September","Oktober","November","Desember"],dayOfWeekShort:["Min","Sen","Sel","Rab","Kam","Jum","Sab"],dayOfWeek:["Minggu","Senin","Selasa","Rabu","Kamis","Jumat","Sabtu"]},is:{months:["Jan\xfaar","Febr\xfaar","Mars","Apr\xedl","Ma\xed","J\xfan\xed","J\xfal\xed","\xc1g\xfast","September","Okt\xf3ber","N\xf3vember","Desember"],dayOfWeekShort:["Sun","M\xe1n","\xderi\xf0","Mi\xf0","Fim","F\xf6s","Lau"],dayOfWeek:["Sunnudagur","M\xe1nudagur","\xderi\xf0judagur","Mi\xf0vikudagur","Fimmtudagur","F\xf6studagur","Laugardagur"]},bg:{months:["\u042f\u043d\u0443\u0430\u0440\u0438","\u0424\u0435\u0432\u0440\u0443\u0430\u0440\u0438","\u041c\u0430\u0440\u0442","\u0410\u043f\u0440\u0438\u043b","\u041c\u0430\u0439","\u042e\u043d\u0438","\u042e\u043b\u0438","\u0410\u0432\u0433\u0443\u0441\u0442","\u0421\u0435\u043f\u0442\u0435\u043c\u0432\u0440\u0438","\u041e\u043a\u0442\u043e\u043c\u0432\u0440\u0438","\u041d\u043e\u0435\u043c\u0432\u0440\u0438","\u0414\u0435\u043a\u0435\u043c\u0432\u0440\u0438"],dayOfWeekShort:["\u041d\u0434","\u041f\u043d","\u0412\u0442","\u0421\u0440","\u0427\u0442","\u041f\u0442","\u0421\u0431"],dayOfWeek:["\u041d\u0435\u0434\u0435\u043b\u044f","\u041f\u043e\u043d\u0435\u0434\u0435\u043b\u043d\u0438\u043a","\u0412\u0442\u043e\u0440\u043d\u0438\u043a","\u0421\u0440\u044f\u0434\u0430","\u0427\u0435\u0442\u0432\u044a\u0440\u0442\u044a\u043a","\u041f\u0435\u0442\u044a\u043a","\u0421\u044a\u0431\u043e\u0442\u0430"]},fa:{months:["\u0641\u0631\u0648\u0631\u062f\u06cc\u0646","\u0627\u0631\u062f\u06cc\u0628\u0647\u0634\u062a","\u062e\u0631\u062f\u0627\u062f","\u062a\u06cc\u0631","\u0645\u0631\u062f\u0627\u062f","\u0634\u0647\u0631\u06cc\u0648\u0631","\u0645\u0647\u0631","\u0622\u0628\u0627\u0646","\u0622\u0630\u0631","\u062f\u06cc","\u0628\u0647\u0645\u0646","\u0627\u0633\u0641\u0646\u062f"],dayOfWeekShort:["\u06cc\u06a9\u0634\u0646\u0628\u0647","\u062f\u0648\u0634\u0646\u0628\u0647","\u0633\u0647 \u0634\u0646\u0628\u0647","\u0686\u0647\u0627\u0631\u0634\u0646\u0628\u0647","\u067e\u0646\u062c\u0634\u0646\u0628\u0647","\u062c\u0645\u0639\u0647","\u0634\u0646\u0628\u0647"],dayOfWeek:["\u06cc\u06a9\u200c\u0634\u0646\u0628\u0647","\u062f\u0648\u0634\u0646\u0628\u0647","\u0633\u0647\u200c\u0634\u0646\u0628\u0647","\u0686\u0647\u0627\u0631\u0634\u0646\u0628\u0647","\u067e\u0646\u062c\u200c\u0634\u0646\u0628\u0647","\u062c\u0645\u0639\u0647","\u0634\u0646\u0628\u0647","\u06cc\u06a9\u200c\u0634\u0646\u0628\u0647"]},ru:{months:["\u042f\u043d\u0432\u0430\u0440\u044c","\u0424\u0435\u0432\u0440\u0430\u043b\u044c","\u041c\u0430\u0440\u0442","\u0410\u043f\u0440\u0435\u043b\u044c","\u041c\u0430\u0439","\u0418\u044e\u043d\u044c","\u0418\u044e\u043b\u044c","\u0410\u0432\u0433\u0443\u0441\u0442","\u0421\u0435\u043d\u0442\u044f\u0431\u0440\u044c","\u041e\u043a\u0442\u044f\u0431\u0440\u044c","\u041d\u043e\u044f\u0431\u0440\u044c","\u0414\u0435\u043a\u0430\u0431\u0440\u044c"],dayOfWeekShort:["\u0412\u0441","\u041f\u043d","\u0412\u0442","\u0421\u0440","\u0427\u0442","\u041f\u0442","\u0421\u0431"],dayOfWeek:["\u0412\u043e\u0441\u043a\u0440\u0435\u0441\u0435\u043d\u044c\u0435","\u041f\u043e\u043d\u0435\u0434\u0435\u043b\u044c\u043d\u0438\u043a","\u0412\u0442\u043e\u0440\u043d\u0438\u043a","\u0421\u0440\u0435\u0434\u0430","\u0427\u0435\u0442\u0432\u0435\u0440\u0433","\u041f\u044f\u0442\u043d\u0438\u0446\u0430","\u0421\u0443\u0431\u0431\u043e\u0442\u0430"]},uk:{months:["\u0421\u0456\u0447\u0435\u043d\u044c","\u041b\u044e\u0442\u0438\u0439","\u0411\u0435\u0440\u0435\u0437\u0435\u043d\u044c","\u041a\u0432\u0456\u0442\u0435\u043d\u044c","\u0422\u0440\u0430\u0432\u0435\u043d\u044c","\u0427\u0435\u0440\u0432\u0435\u043d\u044c","\u041b\u0438\u043f\u0435\u043d\u044c","\u0421\u0435\u0440\u043f\u0435\u043d\u044c","\u0412\u0435\u0440\u0435\u0441\u0435\u043d\u044c","\u0416\u043e\u0432\u0442\u0435\u043d\u044c","\u041b\u0438\u0441\u0442\u043e\u043f\u0430\u0434","\u0413\u0440\u0443\u0434\u0435\u043d\u044c"],dayOfWeekShort:["\u041d\u0434\u043b","\u041f\u043d\u0434","\u0412\u0442\u0440","\u0421\u0440\u0434","\u0427\u0442\u0432","\u041f\u0442\u043d","\u0421\u0431\u0442"],dayOfWeek:["\u041d\u0435\u0434\u0456\u043b\u044f","\u041f\u043e\u043d\u0435\u0434\u0456\u043b\u043e\u043a","\u0412\u0456\u0432\u0442\u043e\u0440\u043e\u043a","\u0421\u0435\u0440\u0435\u0434\u0430","\u0427\u0435\u0442\u0432\u0435\u0440","\u041f'\u044f\u0442\u043d\u0438\u0446\u044f","\u0421\u0443\u0431\u043e\u0442\u0430"]},en:{months:["January","February","March","April","May","June","July","August","September","October","November","December"],dayOfWeekShort:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],dayOfWeek:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"]},el:{months:["\u0399\u03b1\u03bd\u03bf\u03c5\u03ac\u03c1\u03b9\u03bf\u03c2","\u03a6\u03b5\u03b2\u03c1\u03bf\u03c5\u03ac\u03c1\u03b9\u03bf\u03c2","\u039c\u03ac\u03c1\u03c4\u03b9\u03bf\u03c2","\u0391\u03c0\u03c1\u03af\u03bb\u03b9\u03bf\u03c2","\u039c\u03ac\u03b9\u03bf\u03c2","\u0399\u03bf\u03cd\u03bd\u03b9\u03bf\u03c2","\u0399\u03bf\u03cd\u03bb\u03b9\u03bf\u03c2","\u0391\u03cd\u03b3\u03bf\u03c5\u03c3\u03c4\u03bf\u03c2","\u03a3\u03b5\u03c0\u03c4\u03ad\u03bc\u03b2\u03c1\u03b9\u03bf\u03c2","\u039f\u03ba\u03c4\u03ce\u03b2\u03c1\u03b9\u03bf\u03c2","\u039d\u03bf\u03ad\u03bc\u03b2\u03c1\u03b9\u03bf\u03c2","\u0394\u03b5\u03ba\u03ad\u03bc\u03b2\u03c1\u03b9\u03bf\u03c2"],dayOfWeekShort:["\u039a\u03c5\u03c1","\u0394\u03b5\u03c5","\u03a4\u03c1\u03b9","\u03a4\u03b5\u03c4","\u03a0\u03b5\u03bc","\u03a0\u03b1\u03c1","\u03a3\u03b1\u03b2"],dayOfWeek:["\u039a\u03c5\u03c1\u03b9\u03b1\u03ba\u03ae","\u0394\u03b5\u03c5\u03c4\u03ad\u03c1\u03b1","\u03a4\u03c1\u03af\u03c4\u03b7","\u03a4\u03b5\u03c4\u03ac\u03c1\u03c4\u03b7","\u03a0\u03ad\u03bc\u03c0\u03c4\u03b7","\u03a0\u03b1\u03c1\u03b1\u03c3\u03ba\u03b5\u03c5\u03ae","\u03a3\u03ac\u03b2\u03b2\u03b1\u03c4\u03bf"]},de:{months:["Januar","Februar","M\xe4rz","April","Mai","Juni","Juli","August","September","Oktober","November","Dezember"],dayOfWeekShort:["So","Mo","Di","Mi","Do","Fr","Sa"],dayOfWeek:["Sonntag","Montag","Dienstag","Mittwoch","Donnerstag","Freitag","Samstag"]},nl:{months:["januari","februari","maart","april","mei","juni","juli","augustus","september","oktober","november","december"],dayOfWeekShort:["zo","ma","di","wo","do","vr","za"],dayOfWeek:["zondag","maandag","dinsdag","woensdag","donderdag","vrijdag","zaterdag"]},tr:{months:["Ocak","\u015eubat","Mart","Nisan","May\u0131s","Haziran","Temmuz","A\u011fustos","Eyl\xfcl","Ekim","Kas\u0131m","Aral\u0131k"],dayOfWeekShort:["Paz","Pts","Sal","\xc7ar","Per","Cum","Cts"],dayOfWeek:["Pazar","Pazartesi","Sal\u0131","\xc7ar\u015famba","Per\u015fembe","Cuma","Cumartesi"]},fr:{months:["Janvier","F\xe9vrier","Mars","Avril","Mai","Juin","Juillet","Ao\xfbt","Septembre","Octobre","Novembre","D\xe9cembre"],dayOfWeekShort:["Dim","Lun","Mar","Mer","Jeu","Ven","Sam"],dayOfWeek:["dimanche","lundi","mardi","mercredi","jeudi","vendredi","samedi"]},es:{months:["Enero","Febrero","Marzo","Abril","Mayo","Junio","Julio","Agosto","Septiembre","Octubre","Noviembre","Diciembre"],dayOfWeekShort:["Dom","Lun","Mar","Mi\xe9","Jue","Vie","S\xe1b"],dayOfWeek:["Domingo","Lunes","Martes","Mi\xe9rcoles","Jueves","Viernes","S\xe1bado"]},th:{months:["\u0e21\u0e01\u0e23\u0e32\u0e04\u0e21","\u0e01\u0e38\u0e21\u0e20\u0e32\u0e1e\u0e31\u0e19\u0e18\u0e4c","\u0e21\u0e35\u0e19\u0e32\u0e04\u0e21","\u0e40\u0e21\u0e29\u0e32\u0e22\u0e19","\u0e1e\u0e24\u0e29\u0e20\u0e32\u0e04\u0e21","\u0e21\u0e34\u0e16\u0e38\u0e19\u0e32\u0e22\u0e19","\u0e01\u0e23\u0e01\u0e0e\u0e32\u0e04\u0e21","\u0e2a\u0e34\u0e07\u0e2b\u0e32\u0e04\u0e21","\u0e01\u0e31\u0e19\u0e22\u0e32\u0e22\u0e19","\u0e15\u0e38\u0e25\u0e32\u0e04\u0e21","\u0e1e\u0e24\u0e28\u0e08\u0e34\u0e01\u0e32\u0e22\u0e19","\u0e18\u0e31\u0e19\u0e27\u0e32\u0e04\u0e21"],dayOfWeekShort:["\u0e2d\u0e32.","\u0e08.","\u0e2d.","\u0e1e.","\u0e1e\u0e24.","\u0e28.","\u0e2a."],dayOfWeek:["\u0e2d\u0e32\u0e17\u0e34\u0e15\u0e22\u0e4c","\u0e08\u0e31\u0e19\u0e17\u0e23\u0e4c","\u0e2d\u0e31\u0e07\u0e04\u0e32\u0e23","\u0e1e\u0e38\u0e18","\u0e1e\u0e24\u0e2b\u0e31\u0e2a","\u0e28\u0e38\u0e01\u0e23\u0e4c","\u0e40\u0e2a\u0e32\u0e23\u0e4c","\u0e2d\u0e32\u0e17\u0e34\u0e15\u0e22\u0e4c"]},pl:{months:["stycze\u0144","luty","marzec","kwiecie\u0144","maj","czerwiec","lipiec","sierpie\u0144","wrzesie\u0144","pa\u017adziernik","listopad","grudzie\u0144"],dayOfWeekShort:["nd","pn","wt","\u015br","cz","pt","sb"],dayOfWeek:["niedziela","poniedzia\u0142ek","wtorek","\u015broda","czwartek","pi\u0105tek","sobota"]},pt:{months:["Janeiro","Fevereiro","Mar\xe7o","Abril","Maio","Junho","Julho","Agosto","Setembro","Outubro","Novembro","Dezembro"],dayOfWeekShort:["Dom","Seg","Ter","Qua","Qui","Sex","Sab"],dayOfWeek:["Domingo","Segunda","Ter\xe7a","Quarta","Quinta","Sexta","S\xe1bado"]},ch:{months:["\u4e00\u6708","\u4e8c\u6708","\u4e09\u6708","\u56db\u6708","\u4e94\u6708","\u516d\u6708","\u4e03\u6708","\u516b\u6708","\u4e5d\u6708","\u5341\u6708","\u5341\u4e00\u6708","\u5341\u4e8c\u6708"],dayOfWeekShort:["\u65e5","\u4e00","\u4e8c","\u4e09","\u56db","\u4e94","\u516d"]},se:{months:["Januari","Februari","Mars","April","Maj","Juni","Juli","Augusti","September","Oktober","November","December"],dayOfWeekShort:["S\xf6n","M\xe5n","Tis","Ons","Tor","Fre","L\xf6r"]},kr:{months:["1\uc6d4","2\uc6d4","3\uc6d4","4\uc6d4","5\uc6d4","6\uc6d4","7\uc6d4","8\uc6d4","9\uc6d4","10\uc6d4","11\uc6d4","12\uc6d4"],dayOfWeekShort:["\uc77c","\uc6d4","\ud654","\uc218","\ubaa9","\uae08","\ud1a0"],dayOfWeek:["\uc77c\uc694\uc77c","\uc6d4\uc694\uc77c","\ud654\uc694\uc77c","\uc218\uc694\uc77c","\ubaa9\uc694\uc77c","\uae08\uc694\uc77c","\ud1a0\uc694\uc77c"]},it:{months:["Gennaio","Febbraio","Marzo","Aprile","Maggio","Giugno","Luglio","Agosto","Settembre","Ottobre","Novembre","Dicembre"],dayOfWeekShort:["Dom","Lun","Mar","Mer","Gio","Ven","Sab"],dayOfWeek:["Domenica","Luned\xec","Marted\xec","Mercoled\xec","Gioved\xec","Venerd\xec","Sabato"]},da:{months:["January","Februar","Marts","April","Maj","Juni","July","August","September","Oktober","November","December"],dayOfWeekShort:["S\xf8n","Man","Tir","Ons","Tor","Fre","L\xf8r"],dayOfWeek:["s\xf8ndag","mandag","tirsdag","onsdag","torsdag","fredag","l\xf8rdag"]},no:{months:["Januar","Februar","Mars","April","Mai","Juni","Juli","August","September","Oktober","November","Desember"],dayOfWeekShort:["S\xf8n","Man","Tir","Ons","Tor","Fre","L\xf8r"],dayOfWeek:["S\xf8ndag","Mandag","Tirsdag","Onsdag","Torsdag","Fredag","L\xf8rdag"]},ja:{months:["1\u6708","2\u6708","3\u6708","4\u6708","5\u6708","6\u6708","7\u6708","8\u6708","9\u6708","10\u6708","11\u6708","12\u6708"],dayOfWeekShort:["\u65e5","\u6708","\u706b","\u6c34","\u6728","\u91d1","\u571f"],dayOfWeek:["\u65e5\u66dc","\u6708\u66dc","\u706b\u66dc","\u6c34\u66dc","\u6728\u66dc","\u91d1\u66dc","\u571f\u66dc"]},vi:{months:["Th\xe1ng 1","Th\xe1ng 2","Th\xe1ng 3","Th\xe1ng 4","Th\xe1ng 5","Th\xe1ng 6","Th\xe1ng 7","Th\xe1ng 8","Th\xe1ng 9","Th\xe1ng 10","Th\xe1ng 11","Th\xe1ng 12"],dayOfWeekShort:["CN","T2","T3","T4","T5","T6","T7"],dayOfWeek:["Ch\u1ee7 nh\u1eadt","Th\u1ee9 hai","Th\u1ee9 ba","Th\u1ee9 t\u01b0","Th\u1ee9 n\u0103m","Th\u1ee9 s\xe1u","Th\u1ee9 b\u1ea3y"]},sl:{months:["Januar","Februar","Marec","April","Maj","Junij","Julij","Avgust","September","Oktober","November","December"],dayOfWeekShort:["Ned","Pon","Tor","Sre","\u010cet","Pet","Sob"],dayOfWeek:["Nedelja","Ponedeljek","Torek","Sreda","\u010cetrtek","Petek","Sobota"]},cs:{months:["Leden","\xdanor","B\u0159ezen","Duben","Kv\u011bten","\u010cerven","\u010cervenec","Srpen","Z\xe1\u0159\xed","\u0158\xedjen","Listopad","Prosinec"],dayOfWeekShort:["Ne","Po","\xdat","St","\u010ct","P\xe1","So"]},hu:{months:["Janu\xe1r","Febru\xe1r","M\xe1rcius","\xc1prilis","M\xe1jus","J\xfanius","J\xfalius","Augusztus","Szeptember","Okt\xf3ber","November","December"],dayOfWeekShort:["Va","H\xe9","Ke","Sze","Cs","P\xe9","Szo"],dayOfWeek:["vas\xe1rnap","h\xe9tf\u0151","kedd","szerda","cs\xfct\xf6rt\xf6k","p\xe9ntek","szombat"]},az:{months:["Yanvar","Fevral","Mart","Aprel","May","Iyun","Iyul","Avqust","Sentyabr","Oktyabr","Noyabr","Dekabr"],dayOfWeekShort:["B","Be","\xc7a","\xc7","Ca","C","\u015e"],dayOfWeek:["Bazar","Bazar ert\u0259si","\xc7\u0259r\u015f\u0259nb\u0259 ax\u015fam\u0131","\xc7\u0259r\u015f\u0259nb\u0259","C\xfcm\u0259 ax\u015fam\u0131","C\xfcm\u0259","\u015e\u0259nb\u0259"]},bs:{months:["Januar","Februar","Mart","April","Maj","Jun","Jul","Avgust","Septembar","Oktobar","Novembar","Decembar"],dayOfWeekShort:["Ned","Pon","Uto","Sri","\u010cet","Pet","Sub"],dayOfWeek:["Nedjelja","Ponedjeljak","Utorak","Srijeda","\u010cetvrtak","Petak","Subota"]},ca:{months:["Gener","Febrer","Mar\xe7","Abril","Maig","Juny","Juliol","Agost","Setembre","Octubre","Novembre","Desembre"],dayOfWeekShort:["Dg","Dl","Dt","Dc","Dj","Dv","Ds"],dayOfWeek:["Diumenge","Dilluns","Dimarts","Dimecres","Dijous","Divendres","Dissabte"]},"en-GB":{months:["January","February","March","April","May","June","July","August","September","October","November","December"],dayOfWeekShort:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],dayOfWeek:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"]},et:{months:["Jaanuar","Veebruar","M\xe4rts","Aprill","Mai","Juuni","Juuli","August","September","Oktoober","November","Detsember"],dayOfWeekShort:["P","E","T","K","N","R","L"],dayOfWeek:["P\xfchap\xe4ev","Esmasp\xe4ev","Teisip\xe4ev","Kolmap\xe4ev","Neljap\xe4ev","Reede","Laup\xe4ev"]},eu:{months:["Urtarrila","Otsaila","Martxoa","Apirila","Maiatza","Ekaina","Uztaila","Abuztua","Iraila","Urria","Azaroa","Abendua"],dayOfWeekShort:["Ig.","Al.","Ar.","Az.","Og.","Or.","La."],dayOfWeek:["Igandea","Astelehena","Asteartea","Asteazkena","Osteguna","Ostirala","Larunbata"]},fi:{months:["Tammikuu","Helmikuu","Maaliskuu","Huhtikuu","Toukokuu","Kes\xe4kuu","Hein\xe4kuu","Elokuu","Syyskuu","Lokakuu","Marraskuu","Joulukuu"],dayOfWeekShort:["Su","Ma","Ti","Ke","To","Pe","La"],dayOfWeek:["sunnuntai","maanantai","tiistai","keskiviikko","torstai","perjantai","lauantai"]},gl:{months:["Xan","Feb","Maz","Abr","Mai","Xun","Xul","Ago","Set","Out","Nov","Dec"],dayOfWeekShort:["Dom","Lun","Mar","Mer","Xov","Ven","Sab"],dayOfWeek:["Domingo","Luns","Martes","M\xe9rcores","Xoves","Venres","S\xe1bado"]},hr:{months:["Sije\u010danj","Velja\u010da","O\u017eujak","Travanj","Svibanj","Lipanj","Srpanj","Kolovoz","Rujan","Listopad","Studeni","Prosinac"],dayOfWeekShort:["Ned","Pon","Uto","Sri","\u010cet","Pet","Sub"],dayOfWeek:["Nedjelja","Ponedjeljak","Utorak","Srijeda","\u010cetvrtak","Petak","Subota"]},ko:{months:["1\uc6d4","2\uc6d4","3\uc6d4","4\uc6d4","5\uc6d4","6\uc6d4","7\uc6d4","8\uc6d4","9\uc6d4","10\uc6d4","11\uc6d4","12\uc6d4"],dayOfWeekShort:["\uc77c","\uc6d4","\ud654","\uc218","\ubaa9","\uae08","\ud1a0"],dayOfWeek:["\uc77c\uc694\uc77c","\uc6d4\uc694\uc77c","\ud654\uc694\uc77c","\uc218\uc694\uc77c","\ubaa9\uc694\uc77c","\uae08\uc694\uc77c","\ud1a0\uc694\uc77c"]},lt:{months:["Sausio","Vasario","Kovo","Baland\u017eio","Gegu\u017e\u0117s","Bir\u017eelio","Liepos","Rugpj\u016b\u010dio","Rugs\u0117jo","Spalio","Lapkri\u010dio","Gruod\u017eio"],dayOfWeekShort:["Sek","Pir","Ant","Tre","Ket","Pen","\u0160e\u0161"],dayOfWeek:["Sekmadienis","Pirmadienis","Antradienis","Tre\u010diadienis","Ketvirtadienis","Penktadienis","\u0160e\u0161tadienis"]},lv:{months:["Janv\u0101ris","Febru\u0101ris","Marts","Apr\u012blis ","Maijs","J\u016bnijs","J\u016blijs","Augusts","Septembris","Oktobris","Novembris","Decembris"],dayOfWeekShort:["Sv","Pr","Ot","Tr","Ct","Pk","St"],dayOfWeek:["Sv\u0113tdiena","Pirmdiena","Otrdiena","Tre\u0161diena","Ceturtdiena","Piektdiena","Sestdiena"]},mk:{months:["\u0458\u0430\u043d\u0443\u0430\u0440\u0438","\u0444\u0435\u0432\u0440\u0443\u0430\u0440\u0438","\u043c\u0430\u0440\u0442","\u0430\u043f\u0440\u0438\u043b","\u043c\u0430\u0458","\u0458\u0443\u043d\u0438","\u0458\u0443\u043b\u0438","\u0430\u0432\u0433\u0443\u0441\u0442","\u0441\u0435\u043f\u0442\u0435\u043c\u0432\u0440\u0438","\u043e\u043a\u0442\u043e\u043c\u0432\u0440\u0438","\u043d\u043e\u0435\u043c\u0432\u0440\u0438","\u0434\u0435\u043a\u0435\u043c\u0432\u0440\u0438"],dayOfWeekShort:["\u043d\u0435\u0434","\u043f\u043e\u043d","\u0432\u0442\u043e","\u0441\u0440\u0435","\u0447\u0435\u0442","\u043f\u0435\u0442","\u0441\u0430\u0431"],dayOfWeek:["\u041d\u0435\u0434\u0435\u043b\u0430","\u041f\u043e\u043d\u0435\u0434\u0435\u043b\u043d\u0438\u043a","\u0412\u0442\u043e\u0440\u043d\u0438\u043a","\u0421\u0440\u0435\u0434\u0430","\u0427\u0435\u0442\u0432\u0440\u0442\u043e\u043a","\u041f\u0435\u0442\u043e\u043a","\u0421\u0430\u0431\u043e\u0442\u0430"]},mn:{months:["1-\u0440 \u0441\u0430\u0440","2-\u0440 \u0441\u0430\u0440","3-\u0440 \u0441\u0430\u0440","4-\u0440 \u0441\u0430\u0440","5-\u0440 \u0441\u0430\u0440","6-\u0440 \u0441\u0430\u0440","7-\u0440 \u0441\u0430\u0440","8-\u0440 \u0441\u0430\u0440","9-\u0440 \u0441\u0430\u0440","10-\u0440 \u0441\u0430\u0440","11-\u0440 \u0441\u0430\u0440","12-\u0440 \u0441\u0430\u0440"],dayOfWeekShort:["\u0414\u0430\u0432","\u041c\u044f\u0433","\u041b\u0445\u0430","\u041f\u04af\u0440","\u0411\u0441\u043d","\u0411\u044f\u043c","\u041d\u044f\u043c"],dayOfWeek:["\u0414\u0430\u0432\u0430\u0430","\u041c\u044f\u0433\u043c\u0430\u0440","\u041b\u0445\u0430\u0433\u0432\u0430","\u041f\u04af\u0440\u044d\u0432","\u0411\u0430\u0430\u0441\u0430\u043d","\u0411\u044f\u043c\u0431\u0430","\u041d\u044f\u043c"]},"pt-BR":{months:["Janeiro","Fevereiro","Mar\xe7o","Abril","Maio","Junho","Julho","Agosto","Setembro","Outubro","Novembro","Dezembro"],dayOfWeekShort:["Dom","Seg","Ter","Qua","Qui","Sex","S\xe1b"],dayOfWeek:["Domingo","Segunda","Ter\xe7a","Quarta","Quinta","Sexta","S\xe1bado"]},sk:{months:["Janu\xe1r","Febru\xe1r","Marec","Apr\xedl","M\xe1j","J\xfan","J\xfal","August","September","Okt\xf3ber","November","December"],dayOfWeekShort:["Ne","Po","Ut","St","\u0160t","Pi","So"],dayOfWeek:["Nede\u013ea","Pondelok","Utorok","Streda","\u0160tvrtok","Piatok","Sobota"]},sq:{months:["Janar","Shkurt","Mars","Prill","Maj","Qershor","Korrik","Gusht","Shtator","Tetor","N\xebntor","Dhjetor"],dayOfWeekShort:["Die","H\xebn","Mar","M\xebr","Enj","Pre","Shtu"],dayOfWeek:["E Diel","E H\xebn\xeb","E Mart\u0113","E M\xebrkur\xeb","E Enjte","E Premte","E Shtun\xeb"]},"sr-YU":{months:["Januar","Februar","Mart","April","Maj","Jun","Jul","Avgust","Septembar","Oktobar","Novembar","Decembar"],dayOfWeekShort:["Ned","Pon","Uto","Sre","\u010det","Pet","Sub"],dayOfWeek:["Nedelja","Ponedeljak","Utorak","Sreda","\u010cetvrtak","Petak","Subota"]},sr:{months:["\u0458\u0430\u043d\u0443\u0430\u0440","\u0444\u0435\u0431\u0440\u0443\u0430\u0440","\u043c\u0430\u0440\u0442","\u0430\u043f\u0440\u0438\u043b","\u043c\u0430\u0458","\u0458\u0443\u043d","\u0458\u0443\u043b","\u0430\u0432\u0433\u0443\u0441\u0442","\u0441\u0435\u043f\u0442\u0435\u043c\u0431\u0430\u0440","\u043e\u043a\u0442\u043e\u0431\u0430\u0440","\u043d\u043e\u0432\u0435\u043c\u0431\u0430\u0440","\u0434\u0435\u0446\u0435\u043c\u0431\u0430\u0440"],dayOfWeekShort:["\u043d\u0435\u0434","\u043f\u043e\u043d","\u0443\u0442\u043e","\u0441\u0440\u0435","\u0447\u0435\u0442","\u043f\u0435\u0442","\u0441\u0443\u0431"],dayOfWeek:["\u041d\u0435\u0434\u0435\u0459\u0430","\u041f\u043e\u043d\u0435\u0434\u0435\u0459\u0430\u043a","\u0423\u0442\u043e\u0440\u0430\u043a","\u0421\u0440\u0435\u0434\u0430","\u0427\u0435\u0442\u0432\u0440\u0442\u0430\u043a","\u041f\u0435\u0442\u0430\u043a","\u0421\u0443\u0431\u043e\u0442\u0430"]},sv:{months:["Januari","Februari","Mars","April","Maj","Juni","Juli","Augusti","September","Oktober","November","December"],dayOfWeekShort:["S\xf6n","M\xe5n","Tis","Ons","Tor","Fre","L\xf6r"],dayOfWeek:["S\xf6ndag","M\xe5ndag","Tisdag","Onsdag","Torsdag","Fredag","L\xf6rdag"]},"zh-TW":{months:["\u4e00\u6708","\u4e8c\u6708","\u4e09\u6708","\u56db\u6708","\u4e94\u6708","\u516d\u6708","\u4e03\u6708","\u516b\u6708","\u4e5d\u6708","\u5341\u6708","\u5341\u4e00\u6708","\u5341\u4e8c\u6708"],dayOfWeekShort:["\u65e5","\u4e00","\u4e8c","\u4e09","\u56db","\u4e94","\u516d"],dayOfWeek:["\u661f\u671f\u65e5","\u661f\u671f\u4e00","\u661f\u671f\u4e8c","\u661f\u671f\u4e09","\u661f\u671f\u56db","\u661f\u671f\u4e94","\u661f\u671f\u516d"]},zh:{months:["\u4e00\u6708","\u4e8c\u6708","\u4e09\u6708","\u56db\u6708","\u4e94\u6708","\u516d\u6708","\u4e03\u6708","\u516b\u6708","\u4e5d\u6708","\u5341\u6708","\u5341\u4e00\u6708","\u5341\u4e8c\u6708"],dayOfWeekShort:["\u65e5","\u4e00","\u4e8c","\u4e09","\u56db","\u4e94","\u516d"],dayOfWeek:["\u661f\u671f\u65e5","\u661f\u671f\u4e00","\u661f\u671f\u4e8c","\u661f\u671f\u4e09","\u661f\u671f\u56db","\u661f\u671f\u4e94","\u661f\u671f\u516d"]},he:{months:["\u05d9\u05e0\u05d5\u05d0\u05e8","\u05e4\u05d1\u05e8\u05d5\u05d0\u05e8","\u05de\u05e8\u05e5","\u05d0\u05e4\u05e8\u05d9\u05dc","\u05de\u05d0\u05d9","\u05d9\u05d5\u05e0\u05d9","\u05d9\u05d5\u05dc\u05d9","\u05d0\u05d5\u05d2\u05d5\u05e1\u05d8","\u05e1\u05e4\u05d8\u05de\u05d1\u05e8","\u05d0\u05d5\u05e7\u05d8\u05d5\u05d1\u05e8","\u05e0\u05d5\u05d1\u05de\u05d1\u05e8","\u05d3\u05e6\u05de\u05d1\u05e8"],dayOfWeekShort:["\u05d0'","\u05d1'","\u05d2'","\u05d3'","\u05d4'","\u05d5'","\u05e9\u05d1\u05ea"],dayOfWeek:["\u05e8\u05d0\u05e9\u05d5\u05df","\u05e9\u05e0\u05d9","\u05e9\u05dc\u05d9\u05e9\u05d9","\u05e8\u05d1\u05d9\u05e2\u05d9","\u05d7\u05de\u05d9\u05e9\u05d9","\u05e9\u05d9\u05e9\u05d9","\u05e9\u05d1\u05ea","\u05e8\u05d0\u05e9\u05d5\u05df"]},hy:{months:["\u0540\u0578\u0582\u0576\u057e\u0561\u0580","\u0553\u0565\u057f\u0580\u057e\u0561\u0580","\u0544\u0561\u0580\u057f","\u0531\u057a\u0580\u056b\u056c","\u0544\u0561\u0575\u056b\u057d","\u0540\u0578\u0582\u0576\u056b\u057d","\u0540\u0578\u0582\u056c\u056b\u057d","\u0555\u0563\u0578\u057d\u057f\u0578\u057d","\u054d\u0565\u057a\u057f\u0565\u0574\u0562\u0565\u0580","\u0540\u0578\u056f\u057f\u0565\u0574\u0562\u0565\u0580","\u0546\u0578\u0575\u0565\u0574\u0562\u0565\u0580","\u0534\u0565\u056f\u057f\u0565\u0574\u0562\u0565\u0580"],dayOfWeekShort:["\u053f\u056b","\u0535\u0580\u056f","\u0535\u0580\u0584","\u0549\u0578\u0580","\u0540\u0576\u0563","\u0548\u0582\u0580\u0562","\u0547\u0562\u0569"],dayOfWeek:["\u053f\u056b\u0580\u0561\u056f\u056b","\u0535\u0580\u056f\u0578\u0582\u0577\u0561\u0562\u0569\u056b","\u0535\u0580\u0565\u0584\u0577\u0561\u0562\u0569\u056b","\u0549\u0578\u0580\u0565\u0584\u0577\u0561\u0562\u0569\u056b","\u0540\u056b\u0576\u0563\u0577\u0561\u0562\u0569\u056b","\u0548\u0582\u0580\u0562\u0561\u0569","\u0547\u0561\u0562\u0561\u0569"]},kg:{months:["\u04ae\u0447\u0442\u04af\u043d \u0430\u0439\u044b","\u0411\u0438\u0440\u0434\u0438\u043d \u0430\u0439\u044b","\u0416\u0430\u043b\u0433\u0430\u043d \u041a\u0443\u0440\u0430\u043d","\u0427\u044b\u043d \u041a\u0443\u0440\u0430\u043d","\u0411\u0443\u0433\u0443","\u041a\u0443\u043b\u0436\u0430","\u0422\u0435\u043a\u0435","\u0411\u0430\u0448 \u041e\u043e\u043d\u0430","\u0410\u044f\u043a \u041e\u043e\u043d\u0430","\u0422\u043e\u0433\u0443\u0437\u0434\u0443\u043d \u0430\u0439\u044b","\u0416\u0435\u0442\u0438\u043d\u0438\u043d \u0430\u0439\u044b","\u0411\u0435\u0448\u0442\u0438\u043d \u0430\u0439\u044b"],dayOfWeekShort:["\u0416\u0435\u043a","\u0414\u04af\u0439","\u0428\u0435\u0439","\u0428\u0430\u0440","\u0411\u0435\u0439","\u0416\u0443\u043c","\u0418\u0448\u0435"],dayOfWeek:["\u0416\u0435\u043a\u0448\u0435\u043c\u0431","\u0414\u04af\u0439\u0448\u04e9\u043c\u0431","\u0428\u0435\u0439\u0448\u0435\u043c\u0431","\u0428\u0430\u0440\u0448\u0435\u043c\u0431","\u0411\u0435\u0439\u0448\u0435\u043c\u0431\u0438","\u0416\u0443\u043c\u0430","\u0418\u0448\u0435\u043d\u0431"]},rm:{months:["Schaner","Favrer","Mars","Avrigl","Matg","Zercladur","Fanadur","Avust","Settember","October","November","December"],dayOfWeekShort:["Du","Gli","Ma","Me","Gie","Ve","So"],dayOfWeek:["Dumengia","Glindesdi","Mardi","Mesemna","Gievgia","Venderdi","Sonda"]},ka:{months:["\u10d8\u10d0\u10dc\u10d5\u10d0\u10e0\u10d8","\u10d7\u10d4\u10d1\u10d4\u10e0\u10d5\u10d0\u10da\u10d8","\u10db\u10d0\u10e0\u10e2\u10d8","\u10d0\u10de\u10e0\u10d8\u10da\u10d8","\u10db\u10d0\u10d8\u10e1\u10d8","\u10d8\u10d5\u10dc\u10d8\u10e1\u10d8","\u10d8\u10d5\u10da\u10d8\u10e1\u10d8","\u10d0\u10d2\u10d5\u10d8\u10e1\u10e2\u10dd","\u10e1\u10d4\u10e5\u10e2\u10d4\u10db\u10d1\u10d4\u10e0\u10d8","\u10dd\u10e5\u10e2\u10dd\u10db\u10d1\u10d4\u10e0\u10d8","\u10dc\u10dd\u10d4\u10db\u10d1\u10d4\u10e0\u10d8","\u10d3\u10d4\u10d9\u10d4\u10db\u10d1\u10d4\u10e0\u10d8"],dayOfWeekShort:["\u10d9\u10d5","\u10dd\u10e0\u10e8","\u10e1\u10d0\u10db\u10e8","\u10dd\u10d7\u10ee","\u10ee\u10e3\u10d7","\u10de\u10d0\u10e0","\u10e8\u10d0\u10d1"],dayOfWeek:["\u10d9\u10d5\u10d8\u10e0\u10d0","\u10dd\u10e0\u10e8\u10d0\u10d1\u10d0\u10d7\u10d8","\u10e1\u10d0\u10db\u10e8\u10d0\u10d1\u10d0\u10d7\u10d8","\u10dd\u10d7\u10ee\u10e8\u10d0\u10d1\u10d0\u10d7\u10d8","\u10ee\u10e3\u10d7\u10e8\u10d0\u10d1\u10d0\u10d7\u10d8","\u10de\u10d0\u10e0\u10d0\u10e1\u10d9\u10d4\u10d5\u10d8","\u10e8\u10d0\u10d1\u10d0\u10d7\u10d8"]}},value:"",rtl:!1,format:"Y/m/d H:i",formatTime:"H:i",formatDate:"Y/m/d",startDate:!1,step:60,monthChangeSpinner:!0,closeOnDateSelect:!1,closeOnTimeSelect:!0,closeOnWithoutClick:!0,closeOnInputClick:!0,timepicker:!0,datepicker:!0,weeks:!1,defaultTime:!1,defaultDate:!1,minDate:!1,maxDate:!1,minTime:!1,maxTime:!1,disabledMinTime:!1,disabledMaxTime:!1,allowTimes:[],opened:!1,initTime:!0, inline:!1,theme:"",onSelectDate:function(){},onSelectTime:function(){},onChangeMonth:function(){},onGetWeekOfYear:function(){},onChangeYear:function(){},onChangeDateTime:function(){},onShow:function(){},onClose:function(){},onGenerate:function(){},withoutCopyright:!0,inverseButton:!1,hours12:!1,next:"xdsoft_next",prev:"xdsoft_prev",dayOfWeekStart:0,parentID:"body",timeHeightInTimePicker:25,timepickerScrollbar:!0,todayButton:!0,prevButton:!0,nextButton:!0,defaultSelect:!0,scrollMonth:!0,scrollTime:!0,scrollInput:!0,lazyInit:!1,mask:!1,validateOnBlur:!0,allowBlank:!0,yearStart:1950,yearEnd:2050,monthStart:0,monthEnd:11,style:"",id:"",fixed:!1,roundTime:"round",className:"",weekends:[],highlightedDates:[],highlightedPeriods:[],allowDates:[],allowDateRe:null,disabledDates:[],disabledWeekDays:[],yearOffset:0,beforeShowDay:null,enterLikeTab:!0,showApplyButton:!1},r=null,n="en",s="en",a={meridiem:["AM","PM"]},p=function(){var e=i.i18n[s],o={days:e.dayOfWeek,daysShort:e.dayOfWeekShort,months:e.months,monthsShort:t.map(e.months,function(t){return t.substring(0,3)})};r=new DateFormatter({dateSettings:t.extend({},a,o)})};t.datetimepicker={setLocale:function(t){var e=i.i18n[t]?t:n;s!=e&&(s=e,p())},setDateFormatter:function(t){r=t},RFC_2822:"D, d M Y H:i:s O",ATOM:"Y-m-dTH:i:sP",ISO_8601:"Y-m-dTH:i:sO",RFC_822:"D, d M y H:i:s O",RFC_850:"l, d-M-y H:i:s T",RFC_1036:"D, d M y H:i:s O",RFC_1123:"D, d M Y H:i:s O",RSS:"D, d M Y H:i:s O",W3C:"Y-m-dTH:i:sP"},p(),window.getComputedStyle||(window.getComputedStyle=function(t,e){return this.el=t,this.getPropertyValue=function(e){var o=/(\-([a-z]){1})/g;return"float"===e&&(e="styleFloat"),o.test(e)&&(e=e.replace(o,function(t,e,o){return o.toUpperCase()})),t.currentStyle[e]||null},this}),Array.prototype.indexOf||(Array.prototype.indexOf=function(t,e){var o,i;for(o=e||0,i=this.length;i>o;o+=1)if(this[o]===t)return o;return-1}),Date.prototype.countDaysInMonth=function(){return new Date(this.getFullYear(),this.getMonth()+1,0).getDate()},t.fn.xdsoftScroller=function(e){return this.each(function(){var o,i,r,n,s,a=t(this),p=function(t){var e,o={x:0,y:0};return"touchstart"===t.type||"touchmove"===t.type||"touchend"===t.type||"touchcancel"===t.type?(e=t.originalEvent.touches[0]||t.originalEvent.changedTouches[0],o.x=e.clientX,o.y=e.clientY):("mousedown"===t.type||"mouseup"===t.type||"mousemove"===t.type||"mouseover"===t.type||"mouseout"===t.type||"mouseenter"===t.type||"mouseleave"===t.type)&&(o.x=t.clientX,o.y=t.clientY),o},h=100,u=!1,l=0,c=0,f=0,y=!1,d=0,g=function(){};return"hide"===e?void a.find(".xdsoft_scrollbar").hide():(t(this).hasClass("xdsoft_scroller_box")||(o=a.children().eq(0),i=a[0].clientHeight,r=o[0].offsetHeight,n=t('<div class="xdsoft_scrollbar"></div>'),s=t('<div class="xdsoft_scroller"></div>'),n.append(s),a.addClass("xdsoft_scroller_box").append(n),g=function(t){var e=p(t).y-l+d;0>e&&(e=0),e+s[0].offsetHeight>f&&(e=f-s[0].offsetHeight),a.trigger("scroll_element.xdsoft_scroller",[h?e/h:0])},s.on("touchstart.xdsoft_scroller mousedown.xdsoft_scroller",function(o){i||a.trigger("resize_scroll.xdsoft_scroller",[e]),l=p(o).y,d=parseInt(s.css("margin-top"),10),f=n[0].offsetHeight,"mousedown"===o.type||"touchstart"===o.type?(document&&t(document.body).addClass("xdsoft_noselect"),t([document.body,window]).on("touchend mouseup.xdsoft_scroller",function r(){t([document.body,window]).off("touchend mouseup.xdsoft_scroller",r).off("mousemove.xdsoft_scroller",g).removeClass("xdsoft_noselect")}),t(document.body).on("mousemove.xdsoft_scroller",g)):(y=!0,o.stopPropagation(),o.preventDefault())}).on("touchmove",function(t){y&&(t.preventDefault(),g(t))}).on("touchend touchcancel",function(){y=!1,d=0}),a.on("scroll_element.xdsoft_scroller",function(t,e){i||a.trigger("resize_scroll.xdsoft_scroller",[e,!0]),e=e>1?1:0>e||isNaN(e)?0:e,s.css("margin-top",h*e),setTimeout(function(){o.css("marginTop",-parseInt((o[0].offsetHeight-i)*e,10))},10)}).on("resize_scroll.xdsoft_scroller",function(t,e,p){var u,l;i=a[0].clientHeight,r=o[0].offsetHeight,u=i/r,l=u*n[0].offsetHeight,u>1?s.hide():(s.show(),s.css("height",parseInt(l>10?l:10,10)),h=n[0].offsetHeight-s[0].offsetHeight,p!==!0&&a.trigger("scroll_element.xdsoft_scroller",[e||Math.abs(parseInt(o.css("marginTop"),10))/(r-i)]))}),a.on("mousewheel",function(t){var e=Math.abs(parseInt(o.css("marginTop"),10));return e-=20*t.deltaY,0>e&&(e=0),a.trigger("scroll_element.xdsoft_scroller",[e/(r-i)]),t.stopPropagation(),!1}),a.on("touchstart",function(t){u=p(t),c=Math.abs(parseInt(o.css("marginTop"),10))}),a.on("touchmove",function(t){if(u){t.preventDefault();var e=p(t);a.trigger("scroll_element.xdsoft_scroller",[(c-(e.y-u.y))/(r-i)])}}),a.on("touchend touchcancel",function(){u=!1,c=0})),void a.trigger("resize_scroll.xdsoft_scroller",[e]))})},t.fn.datetimepicker=function(n,a){var p,h,u=this,l=48,c=57,f=96,y=105,d=17,g=46,v=13,m=27,b=8,w=37,x=38,S=39,M=40,T=9,P=116,k=65,j=67,A=86,E=90,D=89,C=!1,R=t.isPlainObject(n)||!n?t.extend(!0,{},i,n):t.extend(!0,{},i),L=0,I=function(t){t.on("open.xdsoft focusin.xdsoft mousedown.xdsoft touchstart",function e(){t.is(":disabled")||t.data("xdsoft_datetimepicker")||(clearTimeout(L),L=setTimeout(function(){t.data("xdsoft_datetimepicker")||p(t),t.off("open.xdsoft focusin.xdsoft mousedown.xdsoft touchstart",e).trigger("open.xdsoft")},100))})};return p=function(i){function a(){var t,e=!1;return R.startDate?e=F.strToDate(R.startDate):(e=R.value||(i&&i.val&&i.val()?i.val():""),e?e=F.strToDateTime(e):R.defaultDate&&(e=F.strToDateTime(R.defaultDate),R.defaultTime&&(t=F.strtotime(R.defaultTime),e.setHours(t.getHours()),e.setMinutes(t.getMinutes())))),e&&F.isValidDate(e)?U.data("changed",!0):e="",e||0}function p(e){var o=function(t,e){var o=t.replace(/([\[\]\/\{\}\(\)\-\.\+]{1})/g,"\\$1").replace(/_/g,"{digit+}").replace(/([0-9]{1})/g,"{digit$1}").replace(/\{digit([0-9]{1})\}/g,"[0-$1_]{1}").replace(/\{digit[\+]\}/g,"[0-9_]{1}");return new RegExp(o).test(e)},r=function(t){try{if(document.selection&&document.selection.createRange){var e=document.selection.createRange();return e.getBookmark().charCodeAt(2)-2}if(t.setSelectionRange)return t.selectionStart}catch(o){return 0}},n=function(t,e){if(t="string"==typeof t||t instanceof String?document.getElementById(t):t,!t)return!1;if(t.createTextRange){var o=t.createTextRange();return o.collapse(!0),o.moveEnd("character",e),o.moveStart("character",e),o.select(),!0}return t.setSelectionRange?(t.setSelectionRange(e,e),!0):!1};e.mask&&i.off("keydown.xdsoft"),e.mask===!0&&("undefined"!=typeof moment?e.mask=e.format.replace(/Y{4}/g,"9999").replace(/Y{2}/g,"99").replace(/M{2}/g,"19").replace(/D{2}/g,"39").replace(/H{2}/g,"29").replace(/m{2}/g,"59").replace(/s{2}/g,"59"):e.mask=e.format.replace(/Y/g,"9999").replace(/F/g,"9999").replace(/m/g,"19").replace(/d/g,"39").replace(/H/g,"29").replace(/i/g,"59").replace(/s/g,"59")),"string"===t.type(e.mask)&&(o(e.mask,i.val())||(i.val(e.mask.replace(/[0-9]/g,"_")),n(i[0],0)),i.on("keydown.xdsoft",function(s){var a,p,h=this.value,u=s.which;if(u>=l&&c>=u||u>=f&&y>=u||u===b||u===g){for(a=r(this),p=u!==b&&u!==g?String.fromCharCode(u>=f&&y>=u?u-l:u):"_",u!==b&&u!==g||!a||(a-=1,p="_");/[^0-9_]/.test(e.mask.substr(a,1))&&a<e.mask.length&&a>0;)a+=u===b||u===g?-1:1;if(h=h.substr(0,a)+p+h.substr(a+1),""===t.trim(h))h=e.mask.replace(/[0-9]/g,"_");else if(a===e.mask.length)return s.preventDefault(),!1;for(a+=u===b||u===g?0:1;/[^0-9_]/.test(e.mask.substr(a,1))&&a<e.mask.length&&a>0;)a+=u===b||u===g?-1:1;o(e.mask,h)?(this.value=h,n(this,a)):""===t.trim(h)?this.value=e.mask.replace(/[0-9]/g,"_"):i.trigger("error_input.xdsoft")}else if(-1!==[k,j,A,E,D].indexOf(u)&&C||-1!==[m,x,M,w,S,P,d,T,v].indexOf(u))return!0;return s.preventDefault(),!1}))}var h,u,L,I,O,F,N,U=t('<div class="xdsoft_datetimepicker xdsoft_noselect"></div>'),B=t('<div class="xdsoft_copyright"><a target="_blank" href="http://xdsoft.net/jqplugins/datetimepicker/">xdsoft.net</a></div>'),G=t('<div class="xdsoft_datepicker active"></div>'),W=t('<div class="xdsoft_monthpicker"><button type="button" class="xdsoft_prev"></button><button type="button" class="xdsoft_today_button"></button><div class="xdsoft_label xdsoft_month"><span></span><i></i></div><div class="xdsoft_label xdsoft_year"><span></span><i></i></div><button type="button" class="xdsoft_next"></button></div>'),X=t('<div class="xdsoft_calendar"></div>'),Y=t('<div class="xdsoft_timepicker active"><button type="button" class="xdsoft_prev"></button><div class="xdsoft_time_box"></div><button type="button" class="xdsoft_next"></button></div>'),K=Y.find(".xdsoft_time_box").eq(0),z=t('<div class="xdsoft_time_variant"></div>'),H=t('<button type="button" class="xdsoft_save_selected blue-gradient-button">Save Selected</button>'),V=t('<div class="xdsoft_select xdsoft_monthselect"><div></div></div>'),J=t('<div class="xdsoft_select xdsoft_yearselect"><div></div></div>'),_=!1,Z=0;R.id&&U.attr("id",R.id),R.style&&U.attr("style",R.style),R.weeks&&U.addClass("xdsoft_showweeks"),R.rtl&&U.addClass("xdsoft_rtl"),U.addClass("xdsoft_"+R.theme),U.addClass(R.className),W.find(".xdsoft_month span").after(V),W.find(".xdsoft_year span").after(J),W.find(".xdsoft_month,.xdsoft_year").on("touchstart mousedown.xdsoft",function(e){var o,i,r=t(this).find(".xdsoft_select").eq(0),n=0,s=0,a=r.is(":visible");for(W.find(".xdsoft_select").hide(),F.currentTime&&(n=F.currentTime[t(this).hasClass("xdsoft_month")?"getMonth":"getFullYear"]()),r[a?"hide":"show"](),o=r.find("div.xdsoft_option"),i=0;i<o.length&&o.eq(i).data("value")!==n;i+=1)s+=o[0].offsetHeight;return r.xdsoftScroller(s/(r.children()[0].offsetHeight-r[0].clientHeight)),e.stopPropagation(),!1}),W.find(".xdsoft_select").xdsoftScroller().on("touchstart mousedown.xdsoft",function(t){t.stopPropagation(),t.preventDefault()}).on("touchstart mousedown.xdsoft",".xdsoft_option",function(){(void 0===F.currentTime||null===F.currentTime)&&(F.currentTime=F.now());var e=F.currentTime.getFullYear();F&&F.currentTime&&F.currentTime[t(this).parent().parent().hasClass("xdsoft_monthselect")?"setMonth":"setFullYear"](t(this).data("value")),t(this).parent().parent().hide(),U.trigger("xchange.xdsoft"),R.onChangeMonth&&t.isFunction(R.onChangeMonth)&&R.onChangeMonth.call(U,F.currentTime,U.data("input")),e!==F.currentTime.getFullYear()&&t.isFunction(R.onChangeYear)&&R.onChangeYear.call(U,F.currentTime,U.data("input"))}),U.getValue=function(){return F.getCurrentTime()},U.setOptions=function(o){var n={};R=t.extend(!0,{},R,o),o.allowTimes&&t.isArray(o.allowTimes)&&o.allowTimes.length&&(R.allowTimes=t.extend(!0,[],o.allowTimes)),o.weekends&&t.isArray(o.weekends)&&o.weekends.length&&(R.weekends=t.extend(!0,[],o.weekends)),o.allowDates&&t.isArray(o.allowDates)&&o.allowDates.length&&(R.allowDates=t.extend(!0,[],o.allowDates)),o.allowDateRe&&"[object String]"===Object.prototype.toString.call(o.allowDateRe)&&(R.allowDateRe=new RegExp(o.allowDateRe)),o.highlightedDates&&t.isArray(o.highlightedDates)&&o.highlightedDates.length&&(t.each(o.highlightedDates,function(o,i){var s,a=t.map(i.split(","),t.trim),p=new e(r.parseDate(a[0],R.formatDate),a[1],a[2]),h=r.formatDate(p.date,R.formatDate);void 0!==n[h]?(s=n[h].desc,s&&s.length&&p.desc&&p.desc.length&&(n[h].desc=s+"\n"+p.desc)):n[h]=p}),R.highlightedDates=t.extend(!0,[],n)),o.highlightedPeriods&&t.isArray(o.highlightedPeriods)&&o.highlightedPeriods.length&&(n=t.extend(!0,[],R.highlightedDates),t.each(o.highlightedPeriods,function(o,i){var s,a,p,h,u,l,c;if(t.isArray(i))s=i[0],a=i[1],p=i[2],c=i[3];else{var f=t.map(i.split(","),t.trim);s=r.parseDate(f[0],R.formatDate),a=r.parseDate(f[1],R.formatDate),p=f[2],c=f[3]}for(;a>=s;)h=new e(s,p,c),u=r.formatDate(s,R.formatDate),s.setDate(s.getDate()+1),void 0!==n[u]?(l=n[u].desc,l&&l.length&&h.desc&&h.desc.length&&(n[u].desc=l+"\n"+h.desc)):n[u]=h}),R.highlightedDates=t.extend(!0,[],n)),o.disabledDates&&t.isArray(o.disabledDates)&&o.disabledDates.length&&(R.disabledDates=t.extend(!0,[],o.disabledDates)),o.disabledWeekDays&&t.isArray(o.disabledWeekDays)&&o.disabledWeekDays.length&&(R.disabledWeekDays=t.extend(!0,[],o.disabledWeekDays)),!R.open&&!R.opened||R.inline||i.trigger("open.xdsoft"),R.inline&&(_=!0,U.addClass("xdsoft_inline"),i.after(U).hide()),R.inverseButton&&(R.next="xdsoft_prev",R.prev="xdsoft_next"),R.datepicker?G.addClass("active"):G.removeClass("active"),R.timepicker?Y.addClass("active"):Y.removeClass("active"),R.value&&(F.setCurrentTime(R.value),i&&i.val&&i.val(F.str)),isNaN(R.dayOfWeekStart)?R.dayOfWeekStart=0:R.dayOfWeekStart=parseInt(R.dayOfWeekStart,10)%7,R.timepickerScrollbar||K.xdsoftScroller("hide"),R.minDate&&/^[\+\-](.*)$/.test(R.minDate)&&(R.minDate=r.formatDate(F.strToDateTime(R.minDate),R.formatDate)),R.maxDate&&/^[\+\-](.*)$/.test(R.maxDate)&&(R.maxDate=r.formatDate(F.strToDateTime(R.maxDate),R.formatDate)),H.toggle(R.showApplyButton),W.find(".xdsoft_today_button").css("visibility",R.todayButton?"visible":"hidden"),W.find("."+R.prev).css("visibility",R.prevButton?"visible":"hidden"),W.find("."+R.next).css("visibility",R.nextButton?"visible":"hidden"),p(R),R.validateOnBlur&&i.off("blur.xdsoft").on("blur.xdsoft",function(){if(R.allowBlank&&(!t.trim(t(this).val()).length||"string"==typeof R.mask&&t.trim(t(this).val())===R.mask.replace(/[0-9]/g,"_")))t(this).val(null),U.data("xdsoft_datetime").empty();else{var e=r.parseDate(t(this).val(),R.format);if(e)t(this).val(r.formatDate(e,R.format));else{var o=+[t(this).val()[0],t(this).val()[1]].join(""),i=+[t(this).val()[2],t(this).val()[3]].join("");!R.datepicker&&R.timepicker&&o>=0&&24>o&&i>=0&&60>i?t(this).val([o,i].map(function(t){return t>9?t:"0"+t}).join(":")):t(this).val(r.formatDate(F.now(),R.format))}U.data("xdsoft_datetime").setCurrentTime(t(this).val())}U.trigger("changedatetime.xdsoft"),U.trigger("close.xdsoft")}),R.dayOfWeekStartPrev=0===R.dayOfWeekStart?6:R.dayOfWeekStart-1,U.trigger("xchange.xdsoft").trigger("afterOpen.xdsoft")},U.data("options",R).on("touchstart mousedown.xdsoft",function(t){return t.stopPropagation(),t.preventDefault(),J.hide(),V.hide(),!1}),K.append(z),K.xdsoftScroller(),U.on("afterOpen.xdsoft",function(){K.xdsoftScroller()}),U.append(G).append(Y),R.withoutCopyright!==!0&&U.append(B),G.append(W).append(X).append(H),t(R.parentID).append(U),h=function(){var e=this;e.now=function(t){var o,i,r=new Date;return!t&&R.defaultDate&&(o=e.strToDateTime(R.defaultDate),r.setFullYear(o.getFullYear()),r.setMonth(o.getMonth()),r.setDate(o.getDate())),R.yearOffset&&r.setFullYear(r.getFullYear()+R.yearOffset),!t&&R.defaultTime&&(i=e.strtotime(R.defaultTime),r.setHours(i.getHours()),r.setMinutes(i.getMinutes())),r},e.isValidDate=function(t){return"[object Date]"!==Object.prototype.toString.call(t)?!1:!isNaN(t.getTime())},e.setCurrentTime=function(t,o){"string"==typeof t?e.currentTime=e.strToDateTime(t):e.isValidDate(t)?e.currentTime=t:t||o||!R.allowBlank?e.currentTime=e.now():e.currentTime=null,U.trigger("xchange.xdsoft")},e.empty=function(){e.currentTime=null},e.getCurrentTime=function(t){return e.currentTime},e.nextMonth=function(){(void 0===e.currentTime||null===e.currentTime)&&(e.currentTime=e.now());var o,i=e.currentTime.getMonth()+1;return 12===i&&(e.currentTime.setFullYear(e.currentTime.getFullYear()+1),i=0),o=e.currentTime.getFullYear(),e.currentTime.setDate(Math.min(new Date(e.currentTime.getFullYear(),i+1,0).getDate(),e.currentTime.getDate())),e.currentTime.setMonth(i),R.onChangeMonth&&t.isFunction(R.onChangeMonth)&&R.onChangeMonth.call(U,F.currentTime,U.data("input")),o!==e.currentTime.getFullYear()&&t.isFunction(R.onChangeYear)&&R.onChangeYear.call(U,F.currentTime,U.data("input")),U.trigger("xchange.xdsoft"),i},e.prevMonth=function(){(void 0===e.currentTime||null===e.currentTime)&&(e.currentTime=e.now());var o=e.currentTime.getMonth()-1;return-1===o&&(e.currentTime.setFullYear(e.currentTime.getFullYear()-1),o=11),e.currentTime.setDate(Math.min(new Date(e.currentTime.getFullYear(),o+1,0).getDate(),e.currentTime.getDate())),e.currentTime.setMonth(o),R.onChangeMonth&&t.isFunction(R.onChangeMonth)&&R.onChangeMonth.call(U,F.currentTime,U.data("input")),U.trigger("xchange.xdsoft"),o},e.getWeekOfYear=function(e){if(R.onGetWeekOfYear&&t.isFunction(R.onGetWeekOfYear)){var o=R.onGetWeekOfYear.call(U,e);if("undefined"!=typeof o)return o}var i=new Date(e.getFullYear(),0,1);return 4!=i.getDay()&&i.setMonth(0,1+(4-i.getDay()+7)%7),Math.ceil(((e-i)/864e5+i.getDay()+1)/7)},e.strToDateTime=function(t){var o,i,n=[];return t&&t instanceof Date&&e.isValidDate(t)?t:(n=/^(\+|\-)(.*)$/.exec(t),n&&(n[2]=r.parseDate(n[2],R.formatDate)),n&&n[2]?(o=n[2].getTime()-6e4*n[2].getTimezoneOffset(),i=new Date(e.now(!0).getTime()+parseInt(n[1]+"1",10)*o)):i=t?r.parseDate(t,R.format):e.now(),e.isValidDate(i)||(i=e.now()),i)},e.strToDate=function(t){if(t&&t instanceof Date&&e.isValidDate(t))return t;var o=t?r.parseDate(t,R.formatDate):e.now(!0);return e.isValidDate(o)||(o=e.now(!0)),o},e.strtotime=function(t){if(t&&t instanceof Date&&e.isValidDate(t))return t;var o=t?r.parseDate(t,R.formatTime):e.now(!0);return e.isValidDate(o)||(o=e.now(!0)),o},e.str=function(){return r.formatDate(e.currentTime,R.format)},e.currentTime=this.now()},F=new h,H.on("touchend click",function(t){t.preventDefault(),U.data("changed",!0),F.setCurrentTime(a()),i.val(F.str()),U.trigger("close.xdsoft")}),W.find(".xdsoft_today_button").on("touchend mousedown.xdsoft",function(){U.data("changed",!0),F.setCurrentTime(0,!0),U.trigger("afterOpen.xdsoft")}).on("dblclick.xdsoft",function(){var t,e,o=F.getCurrentTime();o=new Date(o.getFullYear(),o.getMonth(),o.getDate()),t=F.strToDate(R.minDate),t=new Date(t.getFullYear(),t.getMonth(),t.getDate()),t>o||(e=F.strToDate(R.maxDate),e=new Date(e.getFullYear(),e.getMonth(),e.getDate()),o>e||(i.val(F.str()),i.trigger("change"),U.trigger("close.xdsoft")))}),W.find(".xdsoft_prev,.xdsoft_next").on("touchend mousedown.xdsoft",function(){var e=t(this),o=0,i=!1;!function r(t){e.hasClass(R.next)?F.nextMonth():e.hasClass(R.prev)&&F.prevMonth(),R.monthChangeSpinner&&(i||(o=setTimeout(r,t||100)))}(500),t([document.body,window]).on("touchend mouseup.xdsoft",function n(){clearTimeout(o),i=!0,t([document.body,window]).off("touchend mouseup.xdsoft",n)})}),Y.find(".xdsoft_prev,.xdsoft_next").on("touchend mousedown.xdsoft",function(){var e=t(this),o=0,i=!1,r=110;!function n(t){var s=K[0].clientHeight,a=z[0].offsetHeight,p=Math.abs(parseInt(z.css("marginTop"),10));e.hasClass(R.next)&&a-s-R.timeHeightInTimePicker>=p?z.css("marginTop","-"+(p+R.timeHeightInTimePicker)+"px"):e.hasClass(R.prev)&&p-R.timeHeightInTimePicker>=0&&z.css("marginTop","-"+(p-R.timeHeightInTimePicker)+"px"),K.trigger("scroll_element.xdsoft_scroller",[Math.abs(parseInt(z[0].style.marginTop,10)/(a-s))]),r=r>10?10:r-10,i||(o=setTimeout(n,t||r))}(500),t([document.body,window]).on("touchend mouseup.xdsoft",function s(){clearTimeout(o),i=!0,t([document.body,window]).off("touchend mouseup.xdsoft",s)})}),u=0,U.on("xchange.xdsoft",function(e){clearTimeout(u),u=setTimeout(function(){if(void 0===F.currentTime||null===F.currentTime){if(R.allowBlank)return;F.currentTime=F.now()}for(var e,o,a,p,h,u,l,c,f,y,d="",g=new Date(F.currentTime.getFullYear(),F.currentTime.getMonth(),1,12,0,0),v=0,m=F.now(),b=!1,w=!1,x=[],S=!0,M="",T="";g.getDay()!==R.dayOfWeekStart;)g.setDate(g.getDate()-1);for(d+="<table><thead><tr>",R.weeks&&(d+="<th></th>"),e=0;7>e;e+=1)d+="<th>"+R.i18n[s].dayOfWeekShort[(e+R.dayOfWeekStart)%7]+"</th>";for(d+="</tr></thead>",d+="<tbody>",R.maxDate!==!1&&(b=F.strToDate(R.maxDate),b=new Date(b.getFullYear(),b.getMonth(),b.getDate(),23,59,59,999)),R.minDate!==!1&&(w=F.strToDate(R.minDate),w=new Date(w.getFullYear(),w.getMonth(),w.getDate()));v<F.currentTime.countDaysInMonth()||g.getDay()!==R.dayOfWeekStart||F.currentTime.getMonth()===g.getMonth();)x=[],v+=1,a=g.getDay(),p=g.getDate(),h=g.getFullYear(),u=g.getMonth(),l=F.getWeekOfYear(g),y="",x.push("xdsoft_date"),c=R.beforeShowDay&&t.isFunction(R.beforeShowDay.call)?R.beforeShowDay.call(U,g):null,R.allowDateRe&&"[object RegExp]"===Object.prototype.toString.call(R.allowDateRe)?R.allowDateRe.test(r.formatDate(g,R.formatDate))||x.push("xdsoft_disabled"):R.allowDates&&R.allowDates.length>0?-1===R.allowDates.indexOf(r.formatDate(g,R.formatDate))&&x.push("xdsoft_disabled"):b!==!1&&g>b||w!==!1&&w>g||c&&c[0]===!1?x.push("xdsoft_disabled"):-1!==R.disabledDates.indexOf(r.formatDate(g,R.formatDate))?x.push("xdsoft_disabled"):-1!==R.disabledWeekDays.indexOf(a)?x.push("xdsoft_disabled"):i.is("[readonly]")&&x.push("xdsoft_disabled"),c&&""!==c[1]&&x.push(c[1]),F.currentTime.getMonth()!==u&&x.push("xdsoft_other_month"),(R.defaultSelect||U.data("changed"))&&r.formatDate(F.currentTime,R.formatDate)===r.formatDate(g,R.formatDate)&&x.push("xdsoft_current"),r.formatDate(m,R.formatDate)===r.formatDate(g,R.formatDate)&&x.push("xdsoft_today"),(0===g.getDay()||6===g.getDay()||-1!==R.weekends.indexOf(r.formatDate(g,R.formatDate)))&&x.push("xdsoft_weekend"),void 0!==R.highlightedDates[r.formatDate(g,R.formatDate)]&&(o=R.highlightedDates[r.formatDate(g,R.formatDate)],x.push(void 0===o.style?"xdsoft_highlighted_default":o.style),y=void 0===o.desc?"":o.desc),R.beforeShowDay&&t.isFunction(R.beforeShowDay)&&x.push(R.beforeShowDay(g)),S&&(d+="<tr>",S=!1,R.weeks&&(d+="<th>"+l+"</th>")),d+='<td data-date="'+p+'" data-month="'+u+'" data-year="'+h+'" class="xdsoft_date xdsoft_day_of_week'+g.getDay()+" "+x.join(" ")+'" title="'+y+'"><div>'+p+"</div></td>",g.getDay()===R.dayOfWeekStartPrev&&(d+="</tr>",S=!0),g.setDate(p+1);if(d+="</tbody></table>",X.html(d),W.find(".xdsoft_label span").eq(0).text(R.i18n[s].months[F.currentTime.getMonth()]),W.find(".xdsoft_label span").eq(1).text(F.currentTime.getFullYear()),M="",T="",u="",f=function(e,o){var n,s,a=F.now(),p=R.allowTimes&&t.isArray(R.allowTimes)&&R.allowTimes.length;a.setHours(e),e=parseInt(a.getHours(),10),a.setMinutes(o),o=parseInt(a.getMinutes(),10),n=new Date(F.currentTime),n.setHours(e),n.setMinutes(o),x=[],R.minDateTime!==!1&&R.minDateTime>n||R.maxTime!==!1&&F.strtotime(R.maxTime).getTime()<a.getTime()||R.minTime!==!1&&F.strtotime(R.minTime).getTime()>a.getTime()?x.push("xdsoft_disabled"):R.minDateTime!==!1&&R.minDateTime>n||R.disabledMinTime!==!1&&a.getTime()>F.strtotime(R.disabledMinTime).getTime()&&R.disabledMaxTime!==!1&&a.getTime()<F.strtotime(R.disabledMaxTime).getTime()?x.push("xdsoft_disabled"):i.is("[readonly]")&&x.push("xdsoft_disabled"),s=new Date(F.currentTime),s.setHours(parseInt(F.currentTime.getHours(),10)),p||s.setMinutes(Math[R.roundTime](F.currentTime.getMinutes()/R.step)*R.step),(R.initTime||R.defaultSelect||U.data("changed"))&&s.getHours()===parseInt(e,10)&&(!p&&R.step>59||s.getMinutes()===parseInt(o,10))&&(R.defaultSelect||U.data("changed")?x.push("xdsoft_current"):R.initTime&&x.push("xdsoft_init_time")),parseInt(m.getHours(),10)===parseInt(e,10)&&parseInt(m.getMinutes(),10)===parseInt(o,10)&&x.push("xdsoft_today"),M+='<div class="xdsoft_time '+x.join(" ")+'" data-hour="'+e+'" data-minute="'+o+'">'+r.formatDate(a,R.formatTime)+"</div>"},R.allowTimes&&t.isArray(R.allowTimes)&&R.allowTimes.length)for(v=0;v<R.allowTimes.length;v+=1)T=F.strtotime(R.allowTimes[v]).getHours(),u=F.strtotime(R.allowTimes[v]).getMinutes(),f(T,u);else for(v=0,e=0;v<(R.hours12?12:24);v+=1)for(e=0;60>e;e+=R.step)T=(10>v?"0":"")+v,u=(10>e?"0":"")+e,f(T,u);for(z.html(M),n="",v=0,v=parseInt(R.yearStart,10)+R.yearOffset;v<=parseInt(R.yearEnd,10)+R.yearOffset;v+=1)n+='<div class="xdsoft_option '+(F.currentTime.getFullYear()===v?"xdsoft_current":"")+'" data-value="'+v+'">'+v+"</div>";for(J.children().eq(0).html(n),v=parseInt(R.monthStart,10),n="";v<=parseInt(R.monthEnd,10);v+=1)n+='<div class="xdsoft_option '+(F.currentTime.getMonth()===v?"xdsoft_current":"")+'" data-value="'+v+'">'+R.i18n[s].months[v]+"</div>";V.children().eq(0).html(n),t(U).trigger("generate.xdsoft")},10),e.stopPropagation()}).on("afterOpen.xdsoft",function(){if(R.timepicker){var t,e,o,i;z.find(".xdsoft_current").length?t=".xdsoft_current":z.find(".xdsoft_init_time").length&&(t=".xdsoft_init_time"),t?(e=K[0].clientHeight,o=z[0].offsetHeight,i=z.find(t).index()*R.timeHeightInTimePicker+1,i>o-e&&(i=o-e),K.trigger("scroll_element.xdsoft_scroller",[parseInt(i,10)/(o-e)])):K.trigger("scroll_element.xdsoft_scroller",[0])}}),L=0,X.on("touchend click.xdsoft","td",function(e){e.stopPropagation(),L+=1;var o=t(this),r=F.currentTime;return(void 0===r||null===r)&&(F.currentTime=F.now(),r=F.currentTime),o.hasClass("xdsoft_disabled")?!1:(r.setDate(1),r.setFullYear(o.data("year")),r.setMonth(o.data("month")),r.setDate(o.data("date")),U.trigger("select.xdsoft",[r]),i.val(F.str()),R.onSelectDate&&t.isFunction(R.onSelectDate)&&R.onSelectDate.call(U,F.currentTime,U.data("input"),e),U.data("changed",!0),U.trigger("xchange.xdsoft"),U.trigger("changedatetime.xdsoft"),(L>1||R.closeOnDateSelect===!0||R.closeOnDateSelect===!1&&!R.timepicker)&&!R.inline&&U.trigger("close.xdsoft"),void setTimeout(function(){L=0},200))}),z.on("touchmove","div",function(){o=!0}).on("touchend click.xdsoft","div",function(e){if(e.stopPropagation(),o)return void(o=!1);var i=t(this),r=F.currentTime;return(void 0===r||null===r)&&(F.currentTime=F.now(),r=F.currentTime),i.hasClass("xdsoft_disabled")?!1:(r.setHours(i.data("hour")),r.setMinutes(i.data("minute")),U.trigger("select.xdsoft",[r]),U.data("input").val(F.str()),R.onSelectTime&&t.isFunction(R.onSelectTime)&&R.onSelectTime.call(U,F.currentTime,U.data("input"),e),U.data("changed",!0),U.trigger("xchange.xdsoft"),U.trigger("changedatetime.xdsoft"),void(R.inline!==!0&&R.closeOnTimeSelect===!0&&U.trigger("close.xdsoft")))}),G.on("mousewheel.xdsoft",function(t){return R.scrollMonth?(t.deltaY<0?F.nextMonth():F.prevMonth(),!1):!0}),i.on("mousewheel.xdsoft",function(t){return R.scrollInput?!R.datepicker&&R.timepicker?(I=z.find(".xdsoft_current").length?z.find(".xdsoft_current").eq(0).index():0,I+t.deltaY>=0&&I+t.deltaY<z.children().length&&(I+=t.deltaY),z.children().eq(I).length&&z.children().eq(I).trigger("mousedown"),!1):R.datepicker&&!R.timepicker?(G.trigger(t,[t.deltaY,t.deltaX,t.deltaY]),i.val&&i.val(F.str()),U.trigger("changedatetime.xdsoft"),!1):void 0:!0}),U.on("changedatetime.xdsoft",function(e){if(R.onChangeDateTime&&t.isFunction(R.onChangeDateTime)){var o=U.data("input");R.onChangeDateTime.call(U,F.currentTime,o,e),delete R.value,o.trigger("change")}}).on("generate.xdsoft",function(){R.onGenerate&&t.isFunction(R.onGenerate)&&R.onGenerate.call(U,F.currentTime,U.data("input")),_&&(U.trigger("afterOpen.xdsoft"),_=!1)}).on("click.xdsoft",function(t){t.stopPropagation()}),I=0,N=function(t,e){do if(t=t.parentNode,e(t)===!1)break;while("HTML"!==t.nodeName)},O=function(){var e,o,i,r,n,s,a,p,h,u,l,c,f;if(p=U.data("input"),e=p.offset(),o=p[0],u="top",i=e.top+o.offsetHeight-1,r=e.left,n="absolute",h=t(window).width(),c=t(window).height(),f=t(window).scrollTop(),document.documentElement.clientWidth-e.left<G.parent().outerWidth(!0)){var y=G.parent().outerWidth(!0)-o.offsetWidth;r-=y}"rtl"===p.parent().css("direction")&&(r-=U.outerWidth()-p.outerWidth()),R.fixed?(i-=f,r-=t(window).scrollLeft(),n="fixed"):(a=!1,N(o,function(t){return"fixed"===window.getComputedStyle(t).getPropertyValue("position")?(a=!0,!1):void 0}),a?(n="fixed",i+U.outerHeight()>c+f?(u="bottom",i=c+f-e.top):i-=f):i+o.offsetHeight>c+f&&(i=e.top-o.offsetHeight+1),0>i&&(i=0),r+o.offsetWidth>h&&(r=h-o.offsetWidth)),s=U[0],N(s,function(t){var e;return e=window.getComputedStyle(t).getPropertyValue("position"),"relative"===e&&h>=t.offsetWidth?(r-=(h-t.offsetWidth)/2,!1):void 0}),l={position:n,left:r,top:"",bottom:""},l[u]=i,U.css(l)},U.on("open.xdsoft",function(e){var o=!0;R.onShow&&t.isFunction(R.onShow)&&(o=R.onShow.call(U,F.currentTime,U.data("input"),e)),o!==!1&&(U.show(),O(),t(window).off("resize.xdsoft",O).on("resize.xdsoft",O),R.closeOnWithoutClick&&t([document.body,window]).on("touchstart mousedown.xdsoft",function i(){U.trigger("close.xdsoft"),t([document.body,window]).off("touchstart mousedown.xdsoft",i)}))}).on("close.xdsoft",function(e){var o=!0;W.find(".xdsoft_month,.xdsoft_year").find(".xdsoft_select").hide(),R.onClose&&t.isFunction(R.onClose)&&(o=R.onClose.call(U,F.currentTime,U.data("input"),e)),o===!1||R.opened||R.inline||U.hide(),e.stopPropagation()}).on("toggle.xdsoft",function(){U.is(":visible")?U.trigger("close.xdsoft"):U.trigger("open.xdsoft")}).data("input",i),Z=0,U.data("xdsoft_datetime",F),U.setOptions(R),F.setCurrentTime(a()),i.data("xdsoft_datetimepicker",U).on("open.xdsoft focusin.xdsoft mousedown.xdsoft touchstart",function(){i.is(":disabled")||i.data("xdsoft_datetimepicker").is(":visible")&&R.closeOnInputClick||(clearTimeout(Z),Z=setTimeout(function(){i.is(":disabled")||(_=!0,F.setCurrentTime(a(),!0),R.mask&&p(R),U.trigger("open.xdsoft"))},100))}).on("keydown.xdsoft",function(e){var o,i=e.which;return-1!==[v].indexOf(i)&&R.enterLikeTab?(o=t("input:visible,textarea:visible,button:visible,a:visible"),U.trigger("close.xdsoft"),o.eq(o.index(this)+1).focus(),!1):-1!==[T].indexOf(i)?(U.trigger("close.xdsoft"),!0):void 0}).on("blur.xdsoft",function(){U.trigger("close.xdsoft")})},h=function(e){var o=e.data("xdsoft_datetimepicker");o&&(o.data("xdsoft_datetime",null),o.remove(),e.data("xdsoft_datetimepicker",null).off(".xdsoft"),t(window).off("resize.xdsoft"),t([window,document.body]).off("mousedown.xdsoft touchstart"),e.unmousewheel&&e.unmousewheel())},t(document).off("keydown.xdsoftctrl keyup.xdsoftctrl").on("keydown.xdsoftctrl",function(t){t.keyCode===d&&(C=!0)}).on("keyup.xdsoftctrl",function(t){t.keyCode===d&&(C=!1)}),this.each(function(){var e,o=t(this).data("xdsoft_datetimepicker");if(o){if("string"===t.type(n))switch(n){case"show":t(this).select().focus(),o.trigger("open.xdsoft");break;case"hide":o.trigger("close.xdsoft");break;case"toggle":o.trigger("toggle.xdsoft");break;case"destroy":h(t(this));break;case"reset":this.value=this.defaultValue,this.value&&o.data("xdsoft_datetime").isValidDate(r.parseDate(this.value,R.format))||o.data("changed",!1),o.data("xdsoft_datetime").setCurrentTime(this.value);break;case"validate":e=o.data("input"),e.trigger("blur.xdsoft");break;default:o[n]&&t.isFunction(o[n])&&(u=o[n](a))}else o.setOptions(n);return 0}"string"!==t.type(n)&&(!R.lazyInit||R.open||R.inline?p(t(this)):I(t(this)))}),u},t.fn.datetimepicker.defaults=i}),/*! * jQuery Mousewheel 3.1.13 * * Copyright jQuery Foundation and other contributors * Released under the MIT license * http://jquery.org/license */ function(t){"function"==typeof define&&define.amd?define(["jquery"],t):"object"==typeof exports?module.exports=t:t(jQuery)}(function(t){function e(e){var s=e||window.event,a=p.call(arguments,1),h=0,l=0,c=0,f=0,y=0,d=0;if(e=t.event.fix(s),e.type="mousewheel","detail"in s&&(c=-1*s.detail),"wheelDelta"in s&&(c=s.wheelDelta),"wheelDeltaY"in s&&(c=s.wheelDeltaY),"wheelDeltaX"in s&&(l=-1*s.wheelDeltaX),"axis"in s&&s.axis===s.HORIZONTAL_AXIS&&(l=-1*c,c=0),h=0===c?l:c,"deltaY"in s&&(c=-1*s.deltaY,h=c),"deltaX"in s&&(l=s.deltaX,0===c&&(h=-1*l)),0!==c||0!==l){if(1===s.deltaMode){var g=t.data(this,"mousewheel-line-height");h*=g,c*=g,l*=g}else if(2===s.deltaMode){var v=t.data(this,"mousewheel-page-height");h*=v,c*=v,l*=v}if(f=Math.max(Math.abs(c),Math.abs(l)),(!n||n>f)&&(n=f,i(s,f)&&(n/=40)),i(s,f)&&(h/=40,l/=40,c/=40),h=Math[h>=1?"floor":"ceil"](h/n),l=Math[l>=1?"floor":"ceil"](l/n),c=Math[c>=1?"floor":"ceil"](c/n),u.settings.normalizeOffset&&this.getBoundingClientRect){var m=this.getBoundingClientRect();y=e.clientX-m.left,d=e.clientY-m.top}return e.deltaX=l,e.deltaY=c,e.deltaFactor=n,e.offsetX=y,e.offsetY=d,e.deltaMode=0,a.unshift(e,h,l,c),r&&clearTimeout(r),r=setTimeout(o,200),(t.event.dispatch||t.event.handle).apply(this,a)}}function o(){n=null}function i(t,e){return u.settings.adjustOldDeltas&&"mousewheel"===t.type&&e%120===0}var r,n,s=["wheel","mousewheel","DOMMouseScroll","MozMousePixelScroll"],a="onwheel"in document||document.documentMode>=9?["wheel"]:["mousewheel","DomMouseScroll","MozMousePixelScroll"],p=Array.prototype.slice;if(t.event.fixHooks)for(var h=s.length;h;)t.event.fixHooks[s[--h]]=t.event.mouseHooks;var u=t.event.special.mousewheel={version:"3.1.12",setup:function(){if(this.addEventListener)for(var o=a.length;o;)this.addEventListener(a[--o],e,!1);else this.onmousewheel=e;t.data(this,"mousewheel-line-height",u.getLineHeight(this)),t.data(this,"mousewheel-page-height",u.getPageHeight(this))},teardown:function(){if(this.removeEventListener)for(var o=a.length;o;)this.removeEventListener(a[--o],e,!1);else this.onmousewheel=null;t.removeData(this,"mousewheel-line-height"),t.removeData(this,"mousewheel-page-height")},getLineHeight:function(e){var o=t(e),i=o["offsetParent"in t.fn?"offsetParent":"parent"]();return i.length||(i=t("body")),parseInt(i.css("fontSize"),10)||parseInt(o.css("fontSize"),10)||16},getPageHeight:function(e){return t(e).height()},settings:{adjustOldDeltas:!0,normalizeOffset:!0}};t.fn.extend({mousewheel:function(t){return t?this.bind("mousewheel",t):this.trigger("mousewheel")},unmousewheel:function(t){return this.unbind("mousewheel",t)}})}),function(){this.SS_Preview=function(){function t(){}return t.mobile_path="/mobile",t.request_path=null,t.form_item=null,t.render=function(){return $("#ss-preview .date").datetimepicker({lang:"ja",roundTime:"ceil",step:30,closeOnDateSelect:!0}),$("#ss-preview .preview").click(function(){var e,o;return e=$("#ss-preview .date").val(),""!==e?(e=e.replace(/[^\d]/g,""),o=t.request_path,o||(o=location.pathname),o=o.replace(RegExp("\\/preview\\d*("+t.mobile_path+")?"),"/preview"+e)+location.search,t.request_path?t.submitFormPreview(o,t.form_item):location.href=o):void 0}),$("#ss-preview .mobile").click(function(){var e,o;return e=$("#ss-preview .date").val(),""!==e?(e=e.replace(/[^\d]/g,""),o=t.request_path,o||(o=location.pathname),o=o.replace(RegExp("\\/preview\\d*("+t.mobile_path+")?"),"/preview"+e+"/mobile")+location.search,t.request_path?t.submitFormPreview(o,t.form_item):location.href=o):void 0}),t.request_path?$('body a [href="#"]').val("onclick","return false;"):void 0},t.submitFormPreview=function(e,o){var i,r;return r=$('meta[name="csrf-token"]').attr("content"),i=$("<form>"),$(i).attr("method","post"),$(i).attr("action",e),t.appendParams(i,"preview_item",o),i.append($("<input/>",{name:"authenticity_token",value:r,type:"hidden"})),i.appendTo("body"),i.submit(),!1},t.appendParams=function(e,o,i){var r,n,s;i.length<=0&&e.append($("<input/>",{name:o+"[]",value:"",type:"hidden"})),n=[];for(r in i)s=i[r],r.match(/^\d+$/)&&(r=""),"object"==typeof s?n.push(t.appendParams(e,o+"["+r+"]",s)):n.push(e.append($("<input/>",{name:o+"["+r+"]",value:s,type:"hidden"})));return n},t}()}.call(this);
3,568.947368
32,772
0.698879
93a7385f682e4f11318d4784ef552115425e5179
2,981
js
JavaScript
script/index.js
tursics/GingerbreadGame
80b33dfef9e57306ce4d11049c07a6b71cdcbdf1
[ "MIT" ]
null
null
null
script/index.js
tursics/GingerbreadGame
80b33dfef9e57306ce4d11049c07a6b71cdcbdf1
[ "MIT" ]
null
null
null
script/index.js
tursics/GingerbreadGame
80b33dfef9e57306ce4d11049c07a6b71cdcbdf1
[ "MIT" ]
null
null
null
//---------------------------- //--- index.js --- //---------------------------- CConfig = new function() { //------------------------ this.init = function() { if(( typeof device !== 'undefined') && (typeof device.platform !== 'undefined')) { if((device.platform == 'iPhone') || (device.platform == 'iPad') || (device.platform == 'iPod touch') || (device.platform == 'iOS')) { this.platform = this.os.ios; } } if((this.platform == this.os.others) && ('blackberry' in window)) { this.platform = this.os.blackberry; } // if( navigator.userAgent.match(/IEMobile\/10\.0/)) { if((this.platform == this.os.others) && (typeof window.external !== 'undefined') && (typeof window.external.notify !== 'undefined')) { this.platform = this.os.windowsPhone; } if((this.platform == this.os.others) && ('WinJS' in window)) { this.platform = this.os.windows; } if((this.platform == this.os.others) && (navigator.mozApps)) { // this.platform = this.os.firefox; } // this.platform = this.os.ios; // this.platform = this.os.windowsPhone; // this.platform = this.os.firefox; // this.royalty = this.license.lite; this.debug = true; // this.screenshot = true; } //------------------------ this.os = { // desktop os: x // mobile os: xx // branded os: xxx windows: 1, windowsPhone: 10, // mac: 2, ios: 20, // android: 30, // kindle: 301, // nook: 302, // no advertisements allowed!!! blackberry: 40, firefox: 50, others: 999 }; this.license = { lite: 0, full: 1 }; //------------------------ this.platform = this.os.others; this.royalty = this.license.full; this.debug = false; this.screenshot = false; //------------------------ }; //---------------------------- /* $( document).ready( function() { CConfig.init(); try { CInternationalization.init(); if( CConfig.screenshot) { $( 'body,html').css( 'overflow', 'hidden'); } $( document).bind( "orientationchange", function( event, orientation) { eventResize(); }); $( window).resize( eventResize); eventResize(); CInit.eventReady(); } catch( e) { if( CConfig.debug) { alert( e); } } }); */ window.onload = function() { CConfig.init(); try { CInternationalization.init(); if( CConfig.screenshot) { // $( 'body,html').css( 'overflow', 'hidden'); } // $( document).bind( "orientationchange", function( event, orientation) { eventResize(); }); // $( window).resize( eventResize); // eventResize(); var init = new CInit(); init.eventReady(); } catch( e) { if( CConfig.debug) { alert( e); } } }; //---------------------------- /* $( document).bind( "mobileinit", function() { $.support.cors = true; $.mobile.allowCrossDomainPages = true; }); */ //---------------------------- /* function eventResize() { try { CInit.eventResize(); } catch( e) { if( CConfig.debug) { alert( e); } } } */ //---------------------------- // eof
22.755725
136
0.529688
93a8b54a9ed4aadef2bde6861324a0bb1d90107f
449
js
JavaScript
wind-speed/observation-types/gust-speed/view.js
longshorej/xdp-apps
9ca7d90315f81da8f46260211164b930bf4b5466
[ "Apache-2.0" ]
1
2019-05-07T17:45:48.000Z
2019-05-07T17:45:48.000Z
wind-speed/observation-types/gust-speed/view.js
longshorej/xdp-apps
9ca7d90315f81da8f46260211164b930bf4b5466
[ "Apache-2.0" ]
3
2019-05-31T05:08:43.000Z
2021-06-12T08:27:41.000Z
wind-speed/observation-types/gust-speed/view.js
longshorej/xdp-apps
9ca7d90315f81da8f46260211164b930bf4b5466
[ "Apache-2.0" ]
7
2019-05-16T06:13:11.000Z
2019-08-30T19:28:20.000Z
function(endDevice, latestObservation) { return { observationsMapValue: 'gustSpeed', observationsMapGauge: 'gustSpeed', fields: { gustSpeed: { value: latestObservation.data.gustSpeed, name: 'Gust Speed', text: latestObservation.data.gustSpeed.toFixed(2) + ' km/h', color: latestObservation.data.gustSpeed > 15 ? 'danger' : 'success', scaleMin: 0, scaleMax: 30 } } }; }
26.411765
76
0.612472
93a98dbb90db534937a41f9d329453d515223a69
677
js
JavaScript
src/models/Admin.js
ditopixels/Domicilios-SE
b6308d521ee74a2e993a8b1d2b3d1d772a0775bb
[ "MIT" ]
null
null
null
src/models/Admin.js
ditopixels/Domicilios-SE
b6308d521ee74a2e993a8b1d2b3d1d772a0775bb
[ "MIT" ]
null
null
null
src/models/Admin.js
ditopixels/Domicilios-SE
b6308d521ee74a2e993a8b1d2b3d1d772a0775bb
[ "MIT" ]
null
null
null
import { Schema, model } from 'mongoose' import bcrypt from 'bcryptjs' import 'babel-polyfill' const adminSchema = new Schema({ username: { type: String, required: true }, password: { type: String, required: true } }) adminSchema.methods.encryptPassword = async(pass) => { try { const salt = await bcrypt.genSalt(10) const hash = await bcrypt.hash(pass, salt) return hash } catch (e) { console.log(e) } } adminSchema.methods.matchPassword = async function(pass) { try { return await bcrypt.compare(pass, this.password) } catch (e) { console.log(e) } } export default model('Admin', adminSchema)
25.074074
58
0.638109
93aae16bb9470f0c6e5b38f5810f35685d337e6b
640
js
JavaScript
server/db/connection.js
Ayush-Kaushik/event-attendee-tracker
be8fba7154fa2ecc2f102b3266b668fcfa47d67c
[ "Apache-2.0" ]
null
null
null
server/db/connection.js
Ayush-Kaushik/event-attendee-tracker
be8fba7154fa2ecc2f102b3266b668fcfa47d67c
[ "Apache-2.0" ]
null
null
null
server/db/connection.js
Ayush-Kaushik/event-attendee-tracker
be8fba7154fa2ecc2f102b3266b668fcfa47d67c
[ "Apache-2.0" ]
null
null
null
const { MongoClient } = require("mongodb"); const connectionString = process.env.ATLAS_URL; const client = new MongoClient(connectionString, { useNewUrlParser: true, useUnifiedTopology: true, }); let dbConnection; const connectToMongoDbServer = (callback) => { client.connect(function (err, db) { if (err || !db) { return callback(err); } dbConnection = db.db("attendeeTracker"); console.log("Successfully connected to MongoDB."); return callback(); }); }; const getDb = () => { return dbConnection; } module.exports = { connectToMongoDbServer, getDb }
20
58
0.632813
93ab72455bad7662034845c1a1c2ff7c0b4475c5
1,267
js
JavaScript
mediana.js
kcuartasa/curso-practico-javascript
2dd8eb9b992660949124d740fbf0d4ff21e7df67
[ "MIT" ]
null
null
null
mediana.js
kcuartasa/curso-practico-javascript
2dd8eb9b992660949124d740fbf0d4ff21e7df67
[ "MIT" ]
null
null
null
mediana.js
kcuartasa/curso-practico-javascript
2dd8eb9b992660949124d740fbf0d4ff21e7df67
[ "MIT" ]
null
null
null
// const lista1 = [ // 400, // 200, // 500, // 400000, // 100, // 600, // ]; // lista1.sort(function(a, b) { // return a - b; // }); // const mitadLista1 = parseInt(lista1.length / 2); // function esPar(numero){ // if (numero % 2 ===0){ // return true; // } else { // return false; // } // } // let mediana; // if(esPar(lista1.length)){ // const elemento1 = lista1[mitadLista1 - 1]; // const elemento2 = lista1[mitadLista1]; // const promedioElemento1y2 = calcularPromedio([elemento1, elemento2]); // mediana = promedioElemento1y2; // } else { // mediana = lista1[mitadLista1]; // } // Promedio function mediaAritmetica (array) { const sumArray = array.reduce((valorActual, valorAgregado) => valorActual + valorAgregado); return sumArray / array.length; }; // Mediana function mediana (array) { const sortedArray = array.sort((a, b) => a - b); const middleList = sortedArray.length / 2; if (array.length % 2 === 0) { const middleLeft = sortedArray[middleList - 1]; const middleRight = sortedArray[middleList]; return mediaAritmetica([middleLeft, middleRight]); } else { return sortedArray[Math.floor(middleList)]; } };
22.625
95
0.590371
93ac1910bb1389d910c23d94ecfe80a426f09753
1,298
js
JavaScript
app/scripts/analytics.js
jin/NUSMods
7f2f612c7f3b958f4afd707f41025363a6ef0c65
[ "MIT" ]
null
null
null
app/scripts/analytics.js
jin/NUSMods
7f2f612c7f3b958f4afd707f41025363a6ef0c65
[ "MIT" ]
null
null
null
app/scripts/analytics.js
jin/NUSMods
7f2f612c7f3b958f4afd707f41025363a6ef0c65
[ "MIT" ]
null
null
null
'use strict'; var Backbone = require('backbone'); // Initializing dimension values may be asynchronous, so we need to queue up // analytics calls in the meantime. Once initialization is complete, flush() // should be called, after which analytics calls will execute immediately as // usual. var argumentsQueue = []; var ga = function (methodName, fieldName) { if (methodName === 'set' && /^dimension\d+$/.test(fieldName)) { window.ga.apply(null, arguments); } else { argumentsQueue.push(arguments); } }; var loadUrl = Backbone.History.prototype.loadUrl; Backbone.History.prototype.loadUrl = function() { var matched = loadUrl.apply(this, arguments); var gaFragment = this.fragment; if (!/^\//.test(gaFragment)) { gaFragment = '/' + gaFragment; } ga('set', 'page', gaFragment); ga('send', 'pageview', gaFragment); return matched; }; module.exports = { flush: function () { ga = window.ga; for (var i = 0; i < argumentsQueue.length; i++) { ga.apply(null, argumentsQueue[i]); } argumentsQueue = []; }, set: function () { Array.prototype.unshift.call(arguments, 'set'); ga.apply(null, arguments); }, track: function () { Array.prototype.unshift.call(arguments, 'send', 'event'); ga.apply(null, arguments); } };
24.961538
76
0.654083
93aced18435565d7b8e76846d910be67976c4d74
7,531
js
JavaScript
src/components/App.js
ademsa/web-page-data
16c5dc984ecf0a10119e7c2c24d77259d8fc62f6
[ "MIT" ]
null
null
null
src/components/App.js
ademsa/web-page-data
16c5dc984ecf0a10119e7c2c24d77259d8fc62f6
[ "MIT" ]
null
null
null
src/components/App.js
ademsa/web-page-data
16c5dc984ecf0a10119e7c2c24d77259d8fc62f6
[ "MIT" ]
null
null
null
import React from 'react'; import './App.css' import Header from './Header'; import Content from './Content'; import Footer from './Footer'; import Message from './Message'; import ArrayOfObjectsToCSV from './../csv'; import Analyze from './../analyze'; export default class App extends React.Component { constructor(props) { super(props); this.domParser = new DOMParser(); this.getInitialState = this.getInitialState.bind(this); this.handleAnalyzeByKey = this.handleAnalyzeByKey.bind(this); this.handleAnalyzeByClick = this.handleAnalyzeByClick.bind(this); this.validateBeforeAnalysis = this.validateBeforeAnalysis.bind(this); this.analyze = this.analyze.bind(this); this.handleResetActionClick = this.handleResetActionClick.bind(this); this.handleMenuItemClick = this.handleMenuItemClick.bind(this); this.handleExportToJSONClick = this.handleExportToJSONClick.bind(this); this.handleExportToCSVClick = this.handleExportToCSVClick.bind(this); this.downloadData = this.downloadData.bind(this); this.closeActionMessage = this.closeActionMessage.bind(this); this.actionInputRef = React.createRef(); this.actionMessageRef = React.createRef(); this.state = { ...this.getInitialState() }; } getInitialState() { return { content: "", contentActionMsg: "", contentMetadataLang: "", contentMetadataDir: {}, contentMetadataTitle: {}, contentMetadataMeta: {}, contentResourcesAnchors: {}, contentResourcesImages: {}, contentResourcesScripts: {}, contentResourcesLinks: {}, contentTablesAll: {}, contentListsUnordered: {}, contentListsOrdered: {}, contentHeadingsH1: {}, contentHeadingsH2: {}, contentHeadingsH3: {}, contentHeadingsH4: {}, contentHeadingsH5: {}, contentElementsArticles: {}, contentElementsSections: {}, contentElementsParagraphs: {}, } } handleAnalyzeByKey(event) { if (event.keyCode !== 13 && event.key !== "Enter") { return; } this.validateBeforeAnalysis(this.actionInputRef.current.value); } handleAnalyzeByClick() { this.validateBeforeAnalysis(this.actionInputRef.current.value); } validateBeforeAnalysis(content) { if (content === "") { this.setState(prevState => ({ ...prevState, contentActionMsg: "Please enter HTML page source.", })); if (this.actionMessageRef.current.className.indexOf("is-active") < 0) { this.actionMessageRef.current.className += " is-active"; } } else { this.setState(prevState => ({ ...prevState, content: content, })); this.analyze(content); } } analyze(content) { let doc = this.domParser.parseFromString(content, "text/html"); let contentState = Analyze(doc); this.setState(prevState => ({ ...prevState, ...contentState, }), () => { document.getElementById("content").scrollIntoView({ "behavior": "smooth", "block": "start" }); }); } handleResetActionClick() { this.actionInputRef.current.value = ""; this.setState(prevState => ({ ...prevState, ...this.getInitialState() })); window.scrollTo({ top: 0, left: 0 }); } handleMenuItemClick(event) { event.preventDefault(); Array.from(document.getElementsByClassName("content-panel")).forEach(element => { if (element.className.indexOf("is-hidden") < 0) { element.className = element.className + " is-hidden"; } }); let panelId = event.currentTarget.href.replace(window.location.href, "").replace("#", "").replace("/", ""); let panelElement = document.getElementById(panelId); if (panelElement !== undefined && panelElement !== null) { panelElement.className = panelElement.className.replace(" is-hidden", ""); panelElement.scrollIntoView({ "behavior": "smooth", "block": "start" }); } } handleExportToJSONClick(event) { let idx = event.currentTarget.dataset.sourceidx; let dataSource = this.state[event.currentTarget.parentElement.dataset.source]; let data = dataSource.data; if (idx !== undefined && !isNaN(idx)) { data = dataSource.data[idx]; } this.downloadData(dataSource.selectors[0], JSON.stringify(data), "application/json", "json"); } handleExportToCSVClick(event) { let idx = parseInt(event.currentTarget.dataset.sourceidx); let source = event.currentTarget.parentElement.dataset.source; let dataSource = this.state[source]; let csv = ""; if (source === "contentTablesAll") { csv = ArrayOfObjectsToCSV(dataSource.data[idx].rows, dataSource.data[idx].headers); } else { if (idx !== undefined && !isNaN(idx)) { csv = ArrayOfObjectsToCSV(dataSource.data[idx]); } else { csv = ArrayOfObjectsToCSV(dataSource.data); } } this.downloadData(dataSource.selectors[0], csv, "text/csv", "csv"); } downloadData(selector, data, dataType, fileExt) { let a = document.createElement("a"); a.style.visibility = "hidden"; a.download = "wpd-" + selector + "-data." + fileExt; a.href = "data:" + dataType + ";charset=utf-8," + encodeURIComponent(data); a.click(); a.remove(); } closeActionMessage() { this.actionMessageRef.current.className = this.actionMessageRef.current.className.replace(" is-active", ""); } componentDidMount() { document.title = 'Web Page Data'; } render() { return ( <React.Fragment> <Header content={this.state.content} actionInputRef={this.actionInputRef} handleAnalyzeByKey={this.handleAnalyzeByKey} handleAnalyzeByClick={this.handleAnalyzeByClick} handleResetActionClick={this.handleResetActionClick} /> <Content handleMenuItemClick={this.handleMenuItemClick} handleExportToJSONClick={this.handleExportToJSONClick} handleExportToCSVClick={this.handleExportToCSVClick} content={this.state.content} contentMetadataLang={this.state.contentMetadataLang} contentMetadataDir={this.state.contentMetadataDir} contentMetadataTitle={this.state.contentMetadataTitle} contentMetadataMeta={this.state.contentMetadataMeta} contentResourcesAnchors={this.state.contentResourcesAnchors} contentResourcesImages={this.state.contentResourcesImages} contentResourcesScripts={this.state.contentResourcesScripts} contentResourcesLinks={this.state.contentResourcesLinks} contentTablesAll={this.state.contentTablesAll} contentListsUnordered={this.state.contentListsUnordered} contentListsOrdered={this.state.contentListsOrdered} contentHeadingsH1={this.state.contentHeadingsH1} contentHeadingsH2={this.state.contentHeadingsH2} contentHeadingsH3={this.state.contentHeadingsH3} contentHeadingsH4={this.state.contentHeadingsH4} contentHeadingsH5={this.state.contentHeadingsH5} contentElementsArticles={this.state.contentElementsArticles} contentElementsSections={this.state.contentElementsSections} contentElementsParagraphs={this.state.contentElementsParagraphs} /> <Footer /> <Message messageRef={this.actionMessageRef} message={this.state.contentActionMsg} closeMessage={this.closeActionMessage} /> </React.Fragment> ); } }
33.7713
112
0.667375
93ae24793df97498794138197b1e7b7b881bc4de
581
js
JavaScript
controllers/booksController.js
scaredofseagles/21-Homework
b347cdf9290855b82bfea82b9ca67e606dba8959
[ "Unlicense" ]
1
2020-11-24T19:10:48.000Z
2020-11-24T19:10:48.000Z
controllers/booksController.js
scaredofseagles/21-Homework
b347cdf9290855b82bfea82b9ca67e606dba8959
[ "Unlicense" ]
null
null
null
controllers/booksController.js
scaredofseagles/21-Homework
b347cdf9290855b82bfea82b9ca67e606dba8959
[ "Unlicense" ]
null
null
null
const db = require("../models") async function findAll(req, res){ let result = await db.Book.find({}) console.log('Retrieved from the database: ', result) res.json(result) } async function create(req, res){ let result = await db.Book.create(req.body) console.log('Sending to saved: ', req.body) } async function remove(req, res){ console.log(`Deleting item id: ${req.params.id} from the database`) let result = await db.Book.findByIdAndDelete({_id: req.params.id}) res.send({message: "Deleted item"}) } module.exports = {findAll, create, remove}
29.05
71
0.679862
93aedf6f83981da37c5efb2d76bd9e1b11b61ba9
3,431
js
JavaScript
app/src/main/assets/www/js/game1.js
harusiku/Japanese-education
89a9fec908d035b3b5a471e1ced6fd093d6fc13f
[ "MIT" ]
null
null
null
app/src/main/assets/www/js/game1.js
harusiku/Japanese-education
89a9fec908d035b3b5a471e1ced6fd093d6fc13f
[ "MIT" ]
null
null
null
app/src/main/assets/www/js/game1.js
harusiku/Japanese-education
89a9fec908d035b3b5a471e1ced6fd093d6fc13f
[ "MIT" ]
null
null
null
var mode=0; let selected_id=-1; let colorname=[['あか','みどり','あお','おれんじ','むらさき'],['きいろ','ももいろ','しろ','くろ','ちゃいろ']]; let imgList = ["img/game/color/red.png", "img/game/color/green.png", "img/game/color/blue.png", "img/game/color/orange.png", "img/game/color/purple.png"]; let eventList = [function(){play_anim(this,"balloon")},function(){play_anim(this,"balloon")},function(){play_anim(this,"balloon")},function(){play_anim(this,"balloon")},function(){play_anim(this,"balloon")}, ]; let imgList_balloon = ["img/game/color/redb.png", "img/game/color/greenb.png", "img/game/color/blueb.png", "img/game/color/orangeb.png", "img/game/color/purpleb.png"]; let eventList_balloon = [function(){},function(){},function(){},function(){},function(){}]; let imgList2 = ["img/game/color/yellow.png", "img/game/color/pink.png", "img/game/color/white.png", "img/game/color/black.png", "img/game/color/brown.png"]; let eventList2 = [function(){play_anim(this,"balloon")},function(){play_anim(this,"balloon")},function(){play_anim(this,"balloon")},function(){play_anim(this,"balloon")},function(){play_anim(this,"balloon")}, ]; let imgList_balloon2 = ["img/game/color/yellowb.png", "img/game/color/pinkb.png", "img/game/color/whiteb.png", "img/game/color/blackb.png", "img/game/color/brownb.png" ]; let soundList = ["img/game/color/red.mp3", "img/game/color/green.mp3", "img/game/color/blue.mp3", "img/game/color/orange.mp3", "img/game/color/purple.mp3", "img/game/color/yellow.mp3", "img/game/color/pink.mp3", "img/game/color/white.mp3", "img/game/color/black.mp3", "img/game/color/brown.mp3"]; let eventList_balloon2 = [function(){},function(){},function(){},function(){},function(){}]; window.addEventListener('load',function(){ nextpage(0); }); function play_anim(elem,name) { selected_id = elem.parentNode.dataset.num; document.getElementById("content").innerHTML=colorname[mode][selected_id]; let element= document.getElementById(name).getElementsByTagName("div")[selected_id]; element.classList.remove("none"); console.log('selected_id: ', selected_id); let _x = Math.floor(Math.random() * document.getElementById("background").width) + "px"; element.style.left = _x; element.classList.add("moveUp"); element.addEventListener('animationend', onTransitionEnd, false); let selected_id2= mode==1?parseInt(selected_id)+5:parseInt(selected_id); console.log('selected_id2: ', selected_id2); music(soundList[selected_id2]); function onTransitionEnd() { element.classList.add("none"); element.classList.remove("moveUp"); } } function nextpage(num){ let elem = document.getElementsByClassName("item"); for(let i of elem){ i.innerHTML=""; } if(num == 0){ document.getElementById("background").setAttribute("src","img/game/color/color_learn1_backgrond.png"); let img_run = new Add_img("container5",imgList,"fadeIn",eventList); img_run.apply(); img_run = new Add_img("balloon",imgList_balloon,"",eventList_balloon); img_run.apply(); mode=0; }else{ document.getElementById("background").setAttribute("src","img/game/color/color_learn2_backgrond.png"); let img_run = new Add_img("container5",imgList2,"fadeIn",eventList2); img_run.apply(); img_run = new Add_img("balloon",imgList_balloon2,"",eventList_balloon2); img_run.apply(); mode=1; } }
36.115789
208
0.686097
93af7b9fe7aaa858f1f0974643afacacd8951ec1
1,726
js
JavaScript
backend/src/middlewares/auth.js
PadRocha/parkingLot
be0432fd22f206a6b3578702ff95cbb25421b89e
[ "MIT" ]
null
null
null
backend/src/middlewares/auth.js
PadRocha/parkingLot
be0432fd22f206a6b3578702ff95cbb25421b89e
[ "MIT" ]
6
2021-03-10T08:28:31.000Z
2022-03-02T07:27:03.000Z
backend/src/middlewares/auth.js
PadRocha/parkingLot
be0432fd22f206a6b3578702ff95cbb25421b89e
[ "MIT" ]
null
null
null
'use strict' const jwt = require('jsonwebtoken'); //* Calls jsonwebtoken const moment = require('moment'); //* Calls moment exports.authorized = (req, res, next) => { if (!req.headers.authorization) return res.status(403).send({ error: 'Forbidden' }); const token = req.headers.authorization.replace(/['"]+/g, '').split(' ')[1]; if (token === 'null') return res.status(403).send({ error: 'Forbidden' }); try { var payload = jwt.verify(token, process.env.SECRET_KEY); if (payload.exp <= moment().unix()) return res.status(423).send({ error: 'The resource that is being accessed is locked' }); } catch (error) { return res.status(409).send({ error: 'Indicates that the request could not be processed because of conflict in the current state of the resourcess' }); } req.user = payload; return next(); } exports.authAdmin = (req, res, next) => { if (!req.headers.authorization) return res.status(403).send({ error: 'Forbidden' }); const token = req.headers.authorization.replace(/['"]+/g, '').split(' ')[1]; if (token === 'null') return res.status(403).send({ error: 'Forbidden' }); try { var payload = jwt.verify(token, process.env.SECRET_KEY); if (payload.exp <= moment().unix()) return res.status(423).send({ error: 'The resource that is being accessed is locked' }); if (payload.role !== 'admin') return res.status(423).send({ error: 'The resource that is being accessed is locked' }); } catch (error) { return res.status(409).send({ error: 'Indicates that the request could not be processed because of conflict in the current state of the resourcess' }); } req.user = payload; return next(); }
42.097561
159
0.640788
93b1060f1cc3d30762c90c4441cc6820e020fc57
862
js
JavaScript
dist/mock/questions.js
lp1dev/Modern-Text-Game-Engine
869f20eca2d0ea5f4e1047add4e9c3deae745887
[ "MIT", "Unlicense" ]
1
2020-05-23T20:07:53.000Z
2020-05-23T20:07:53.000Z
dist/mock/questions.js
lp1dev/Mirage
869f20eca2d0ea5f4e1047add4e9c3deae745887
[ "Unlicense", "MIT" ]
null
null
null
dist/mock/questions.js
lp1dev/Mirage
869f20eca2d0ea5f4e1047add4e9c3deae745887
[ "Unlicense", "MIT" ]
null
null
null
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); var unparsedQuestions = [{ id: 'GAME_INTRO', text: 'T_GAME_INTRO', answers: { 'T_GAME_INTRO1': 'GAME_INTRO2', 'T_GAME_INTRO2': 'CHAPTER1', 'T_GAME_INTRO3': 'GAME_INTRO2' } }, { id: 'CHAPTER1', text: 'T_CHAPTER1', answers: { 'T_CHAPTER1_1': 'set coins 3; CHAPTER1_3', 'T_CHAPTER1_2': 'set coins 0; CHAPTER2' } }, { id: 'GAME_INTRO2', text: 'T_GAME_INTRO2', answers: { 'T_GAME_INTRO2_1': 'CHAPTER1', 'T_GAME_INTRO2_2': 'GAME_INTRO' }, hide: { 'T_GAME_INTRO2_1': 'if coins < 2' } }]; exports.unparsedQuestions = unparsedQuestions; //# sourceMappingURL=questions.js.map
28.733333
62
0.525522
93b1399da45ae522f5a64d7f7da409e5fc64b768
1,999
js
JavaScript
lib/render.js
92hackers/marked
2dde46220b1081d830baad63b4a99b57c33675ac
[ "BSD-3-Clause" ]
null
null
null
lib/render.js
92hackers/marked
2dde46220b1081d830baad63b4a99b57c33675ac
[ "BSD-3-Clause" ]
null
null
null
lib/render.js
92hackers/marked
2dde46220b1081d830baad63b4a99b57c33675ac
[ "BSD-3-Clause" ]
null
null
null
/** * Renderer, convert token sets into html strings. */ import { escape, getDefaultOptions, cleanUrl, } from './utils' class Renderer { constructor(options) { this.options = options || getDefaultOptions() } code(code, infostring, escaped) { } hr() { } list() { } listitem(text) { } checkbox(checked) { return '<input ' + (checked ? 'checked="" ' : '') + 'disabled="" type="checkbox"' + (this.options.xhtml ? ' /' : '') + '> '; } paragraph(text) { return '<p>' + text + '</p>\n'; } table(header, body) { } // span level renderer strong(text) { return '<strong>' + text + '</strong>'; } em(text) { return '<em>' + text + '</em>'; } codespan(text) { return '<code>' + text + '</code>'; } br() { return this.options.xhtml ? '<br/>' : '<br>'; } del(text) { return '<del>' + text + '</del>'; } link(href, title, text) { href = cleanUrl(this.options.sanitize, this.options.baseUrl, href); if (href === null) { return text; } var out = '<a href="' + escape(href) + '"'; if (title) { out += ' title="' + title + '"'; } out += '>' + text + '</a>'; return out; } image(href, title, text) { href = cleanUrl(this.options.sanitize, this.options.baseUrl, href); if (href === null) { return text; } var out = '<img src="' + href + '" alt="' + text + '"'; if (title) { out += ' title="' + title + '"'; } out += this.options.xhtml ? '/>' : '>'; return out; } text(text) { return text; } inlineStyle(styleStr, text) { return `<span style="${styleStr}">${text}</span>` } fontColor(color, text) { return this.inlineStyle(`color: ${color}`, text) } fontBgColor(color, text) { return this.inlineStyle(`background-color: ${color}`, text) } fontSize(size, text) { return this.inlineStyle(`font-size: ${size}px`, text) } } export default Renderer
17.690265
71
0.518759
93b422807f1ec0072d02c20f74ba8b18640f39eb
285
js
JavaScript
server/db/models/account.js
gberzuela/Stackathon
18b5df13e0cadb4b000812fe7853679f9e4a60eb
[ "MIT" ]
null
null
null
server/db/models/account.js
gberzuela/Stackathon
18b5df13e0cadb4b000812fe7853679f9e4a60eb
[ "MIT" ]
null
null
null
server/db/models/account.js
gberzuela/Stackathon
18b5df13e0cadb4b000812fe7853679f9e4a60eb
[ "MIT" ]
1
2021-03-15T22:40:29.000Z
2021-03-15T22:40:29.000Z
const Sequelize = require('sequelize') const db = require('../db') const Account = db.define('account', { accountId: Sequelize.STRING, name: Sequelize.STRING, officialName: Sequelize.STRING, subtype: Sequelize.STRING, balance: Sequelize.DECIMAL }) module.exports = Account
21.923077
38
0.729825
93b5d2a7163e1e1513939f9cfef9b334fa9d2ded
277
js
JavaScript
src/fragments/forms/map-form/components/place-and-directions/components/route-details/components/extras/i18n/route-extras.i18n.fr-fr.js
whpai/eeee
e5e425bb92110f3b3728414f2120b19d72c8cd92
[ "Apache-2.0" ]
45
2020-07-08T16:56:00.000Z
2022-03-13T12:42:23.000Z
src/fragments/forms/map-form/components/place-and-directions/components/route-details/components/extras/i18n/route-extras.i18n.fr-fr.js
whpai/eeee
e5e425bb92110f3b3728414f2120b19d72c8cd92
[ "Apache-2.0" ]
217
2020-07-16T17:13:31.000Z
2022-03-29T19:05:32.000Z
src/fragments/forms/map-form/components/place-and-directions/components/route-details/components/extras/i18n/route-extras.i18n.fr-fr.js
whpai/eeee
e5e425bb92110f3b3728414f2120b19d72c8cd92
[ "Apache-2.0" ]
17
2020-09-30T20:19:44.000Z
2022-03-23T20:49:26.000Z
export default { 'routeExtras': { 'extras': 'Extras d\'itinéraire', 'extraInfo': 'Inform. supplémentaires', 'value': 'Valeur', 'clickToHighlightOnMap': 'Cliquez pour le mettre en évidence sur la carte', 'showAllOnMap': 'Tout afficher sur la carte' } }
25.181818
79
0.65704
93b5fd5b7c63fcd35cbde9059982f12bb14dcacc
39
js
JavaScript
packages/1977/01/24/index.js
antonmedv/year
ae5d8524f58eaad481c2ba599389c7a9a38c0819
[ "MIT" ]
7
2017-07-03T19:53:01.000Z
2021-04-05T18:15:55.000Z
packages/1977/01/24/index.js
antonmedv/year
ae5d8524f58eaad481c2ba599389c7a9a38c0819
[ "MIT" ]
1
2018-09-05T11:53:41.000Z
2018-12-16T12:36:21.000Z
packages/1977/01/24/index.js
antonmedv/year
ae5d8524f58eaad481c2ba599389c7a9a38c0819
[ "MIT" ]
2
2019-01-27T16:57:34.000Z
2020-10-11T09:30:25.000Z
module.exports = new Date(1977, 0, 24)
19.5
38
0.692308
93b9f1c2292701025b5e9f4e900fcbb5c09b5e37
580
js
JavaScript
library/original/lehandsomeguy - Drone.js
k-gopnik/bytebeat-composer
88097836343a12a19db1ed74168bb98d14e06c88
[ "MIT" ]
8
2019-01-15T09:48:07.000Z
2022-02-24T00:37:11.000Z
library/original/lehandsomeguy - Drone.js
k-gopnik/bytebeat-composer
88097836343a12a19db1ed74168bb98d14e06c88
[ "MIT" ]
37
2021-10-10T20:41:51.000Z
2022-03-17T21:56:40.000Z
library/original/lehandsomeguy - Drone.js
k-gopnik/bytebeat-composer
88097836343a12a19db1ed74168bb98d14e06c88
[ "MIT" ]
5
2021-11-03T05:43:55.000Z
2022-03-10T18:11:34.000Z
time = t/11025, PI = 3.14159265358979323, fract=function(x) { return x%1 }, mix=function(a,b,c) { return (a*(1-c))+(b*c) }, tri=function(x) { return asin(sin(x))/(PI/2.) }, puls=function(x) { return (floor(sin(x))+0.5)*2.; }, saw=function(x) { return (fract((x/2.)/PI)-0.5)*2.; }, noise=function(x) { return sin((x+10)*sin(pow((x+10),fract(x)+10))); }, main=function(x) { a = 0; for (j = 0; j < 13; j++) { a += sin((2100+(noise((j+2)+floor(time))*2500))*time)*(1-fract(time*floor(mix(1,5,noise((j+5.24)+floor(time)))))); } return a/9; } , main(time);
20
116
0.551724
93bcfbd6b66bef21c64cbc5e67ac35ca32351ad1
4,250
js
JavaScript
frontReact/src/components/posts/posts.js
Huzzky/mls
979b50cfaa93150e3884ddf6b1a188159a582206
[ "MIT" ]
null
null
null
frontReact/src/components/posts/posts.js
Huzzky/mls
979b50cfaa93150e3884ddf6b1a188159a582206
[ "MIT" ]
null
null
null
frontReact/src/components/posts/posts.js
Huzzky/mls
979b50cfaa93150e3884ddf6b1a188159a582206
[ "MIT" ]
null
null
null
import React, { Component } from 'react' import { getPost } from '../api/http'; import './posts.css' import adminsvg from './img/wrench.svg' import MapInReact from './map/mapInPost'; import DeletePost from './deletePost/deletePost'; class Posts extends Component{ constructor(props) { super(props); this.state = { data: [], isLoaded: false, reversePostDateBool: false, btnDeletePost: false, }; this.getPostFunc = this.getPostFunc.bind(this); this.reversePostDate = this.reversePostDate.bind(this); this.clkBtnDelete=this.clkBtnDelete.bind(this); } getPostFunc(){ getPost() .then( response => { if(response.status>=200){ const DATA_TEST = response.data.posts; this.setState({ data: DATA_TEST, isLoaded:true }); } }) .catch(function(error){ console.log(error); }); } componentDidMount() { this.getPostFunc() } shouldComponentUpdate(nextProps, nextState) { if (nextProps.updatePosts===true || this.props.updatePosts===true) { if(this.state.btnDeletePost===false || this.state.btnDeletePost===true){ this.getPostFunc() this.setState({ bole:false }) this.props.onChan(this.state.bole) } } return true; } reversePostDate() { if (this.state.reversePostDateBool===true){ this.setState({ data: this.state.data.reverse(), reversePostDateBool: false, }) // console.log(this.state.data) } else if (this.state.reversePostDateBool===false){ this.setState({ data: this.state.data.reverse(), reversePostDateBool:true, }) // console.log(this.state.data) } } clkBtnDelete(clickOrNO){ this.setState({ btnDeletePost: clickOrNO, }) } render() { const { data, isLoaded } = this.state; if (data.length>0){ const POSTS_LIST = data.map((value, number) => <div className="mainDiv-post" key={number}> <div className="secDiv-post"> <div className="t-Div-post"> <p className="p-div-post user_post"><img className="img-user-post" src={adminsvg} alt="Admin Img" width="20" height="20"/>{value.user_post}</p> <p className="p-div-post date_post">{value.date_post}</p> </div> <hr className="hr-post"/> <div className="f-div-post"> <p className="p-div-post-content content_post">{value.content_post}</p> {/* <p key={value.id_post} className="p-div-post">Удалить</p> */} </div> <MapInReact long={value.long_loc_post} lat={value.lat_loc_post}/> <div className="down-panel-post"> <DeletePost idPost={value.id_post} clickDeletePost={this.clkBtnDelete}/> <p>Comment</p> </div> </div> </div> ); return( <div> {/* <a onClick={this.reversePostDate}>Sort</a> */} {POSTS_LIST} </div> ) } else if(data.length===0 && isLoaded){ return(<div className="no-post"> <h3 className="post-und">Постов пока что нет, но Вы можете быть одним из первых</h3> </div>) } else if(data.length===0 && !isLoaded){ return(<div className="no-post"> <h3 className="loading">Загрузка, подождие</h3> </div>) } } } export default Posts;
33.464567
105
0.467059
93be171080f2d6d32c71e837ba835f24f680817b
7,714
js
JavaScript
calgary/lambda/us-east-1_ask-custom-calgary-alexa-default/index.js
BraydenHalliday/SSR_permits
061609255ceb4363a22977bb7b956023be490328
[ "MIT" ]
5
2019-03-28T22:36:03.000Z
2021-10-13T14:30:20.000Z
calgary/lambda/us-east-1_ask-custom-calgary-alexa-default/index.js
BraydenHalliday/SSR_permits
061609255ceb4363a22977bb7b956023be490328
[ "MIT" ]
9
2020-11-25T23:34:34.000Z
2022-02-17T21:11:24.000Z
calgary/lambda/us-east-1_ask-custom-calgary-alexa-default/index.js
BraydenHalliday/SSR_permits
061609255ceb4363a22977bb7b956023be490328
[ "MIT" ]
5
2019-04-15T15:23:34.000Z
2021-09-09T13:18:35.000Z
/* eslint-disable func-names */ /* eslint-disable no-console */ const Alexa = require('ask-sdk-core'); const LaunchRequestHandler = { canHandle(handlerInput) { return handlerInput.requestEnvelope.request.type === 'LaunchRequest'; }, handle(handlerInput) { const speechText = 'Welcome to the Alexa Everything Calgary Skills Kit, you can ask for traffic or garbage information in your community!'; return handlerInput.responseBuilder .speak(speechText) .reprompt(speechText) .getResponse(); }, }; const GetRemoteDataHandler = { canHandle(handlerInput) { return (handlerInput.requestEnvelope.request.type === 'IntentRequest' && handlerInput.requestEnvelope.request.intent.name === 'GetRemoteDataIntent'); }, async handle(handlerInput) { let outputSpeech = 'This is the default message.'; const community = handlerInput.requestEnvelope.request.intent.slots.community.value.toUpperCase(); await getRemoteData(`https://data.calgary.ca/resource/g5k5-gjns.json?community=${community}&$select=distinct%20commodity,%20community,%20collection_day,clect_int_winter,clect_int_summer`) .then((response) => { const data = JSON.parse(response); const garbageObj = {}; data.forEach(bin => { const binData = manipulateData(bin) garbageObj[binData[1]] = binData[0] }); outputSpeech = `In ${community}, your next green bin pickup is on ${garbageObj['Green'][1] + garbageObj['Green'][0]}. Your next blue bin pickup is on ${garbageObj['Green'][1] + garbageObj['Green'][0]}. Your next black bin pickup is on ${garbageObj['Black'][1] + garbageObj['Black'][0]}. `; }) .catch((err) => { //set an optional error message here outputSpeech = "This community does not exist."; }); return handlerInput.responseBuilder .speak(outputSpeech) .getResponse(); }, }; const TrafficHandler = { canHandle(handlerInput) { return (handlerInput.requestEnvelope.request.type === 'IntentRequest' && handlerInput.requestEnvelope.request.intent.name === 'Traffic'); }, async handle(handlerInput) { let outputSpeech = 'This is the default message.'; await getRemoteData('https://data.calgary.ca/resource/y5vq-u678.json') .then((response) => { const data = JSON.parse(response); if (data[0].incident_info === 'NO TRAFFIC INCIDENTS'){ outputSpeech = `There are currently no traffic incidents in Calgary. The roads are clear!` } else { if (data.length === 1){ outputSpeech = `There is currently ${data.length} traffic incident.`; } else { outputSpeech = `There are currently ${data.length} traffic incidents.`; } for (let i = 0; i < data.length; i++) { if (i === 0) { //first record outputSpeech = outputSpeech + ' There is a ' + data[i].description.replace('.', '') + ' at ' + data[i].incident_info + ' which started ' + getElapsedTime(data[i].start_dt) + ', ' } else if (i === data.length - 1) { //last record outputSpeech = outputSpeech + ' and a ' + data[i].description.replace('.', '') + ' at ' + data[i].incident_info + ' which started ' + getElapsedTime(data[i].start_dt) + '.' } else { //middle record(s) outputSpeech = outputSpeech + ' a ' + data[i].description.replace('.', '') + ' at ' + data[i].incident_info + ' which started ' + getElapsedTime(data[i].start_dt) + ', ' } } } }) .catch((err) => { //set an optional error message here outputSpeech = `There are currently no traffic incidents in Calgary. The roads are clear!` }); return handlerInput.responseBuilder .speak(outputSpeech) .getResponse(); }, }; const HelpIntentHandler = { canHandle(handlerInput) { return handlerInput.requestEnvelope.request.type === 'IntentRequest' && handlerInput.requestEnvelope.request.intent.name === 'AMAZON.HelpIntent'; }, handle(handlerInput) { const speechText = 'You can introduce yourself by telling me your name'; return handlerInput.responseBuilder .speak(speechText) .reprompt(speechText) .getResponse(); }, }; const CancelAndStopIntentHandler = { canHandle(handlerInput) { return handlerInput.requestEnvelope.request.type === 'IntentRequest' && (handlerInput.requestEnvelope.request.intent.name === 'AMAZON.CancelIntent' || handlerInput.requestEnvelope.request.intent.name === 'AMAZON.StopIntent'); }, handle(handlerInput) { const speechText = 'Goodbye!'; return handlerInput.responseBuilder .speak(speechText) .getResponse(); }, }; const SessionEndedRequestHandler = { canHandle(handlerInput) { return handlerInput.requestEnvelope.request.type === 'SessionEndedRequest'; }, handle(handlerInput) { console.log(`Session ended with reason: ${handlerInput.requestEnvelope.request.reason}`); return handlerInput.responseBuilder.getResponse(); }, }; const ErrorHandler = { canHandle() { return true; }, handle(handlerInput, error) { console.log(`Error handled: ${error.message}`); return handlerInput.responseBuilder .speak('Sorry, I can\'t understand the command. Please say again.') .reprompt('Sorry, I can\'t understand the command. Please say again.') .getResponse(); }, }; const getRemoteData = function (url) { return new Promise((resolve, reject) => { const client = url.startsWith('https') ? require('https') : require('http'); const request = client.get(url, (response) => { if (response.statusCode < 200 || response.statusCode > 299) { reject(new Error('Failed with status code: ' + response.statusCode)); } const body = []; response.on('data', (chunk) => body.push(chunk)); response.on('end', () => resolve(body.join(''))); }); request.on('error', (err) => reject(err)) }) }; const skillBuilder = Alexa.SkillBuilders.custom(); exports.handler = skillBuilder .addRequestHandlers( LaunchRequestHandler, GetRemoteDataHandler, TrafficHandler, HelpIntentHandler, CancelAndStopIntentHandler, SessionEndedRequestHandler ) .addErrorHandlers(ErrorHandler) .lambda(); // HELPER FUNCTIONS function weeksBetween(d1, d2) { return Math.round((d2 - d1) / (7 * 24 * 60 * 60 * 1000)); } function frequency_season (date, data) { if(date.getMonth() > 9 || date.getMonth() < 4) { return data.clect_int_winter; } else { return data.clect_int_summer; } } function manipulateData(data) { let day = data.collection_day; let startDate = new Date("17 July 2017"); let now = new Date(); let x = weeksBetween(startDate, now) % 2; let dataArr = []; switch(frequency_season(now, data)) { case 'EVEN': dataArr[0] = (x===0 ? [day, ' this coming '] : [day, ' the following ']); dataArr[1] = data.commodity; break; case 'ODD': dataArr[0] = (x===1 ? [day, ' this coming '] : [day, ' the following ']); dataArr[1] = data.commodity; break; default: dataArr[0] = ([day, ' this coming ']); dataArr[1] = data.commodity; break; } return dataArr; } function getElapsedTime(date){ let now = new Date(); let happened = new Date(date); var diffMs = (now - happened); // milliseconds between now & accident happeend var diffMins = Math.round(((diffMs % 86400000 + 60000) % 3600000) / 60000 ); // minutes return `${diffMins} minutes ago` }
34.132743
192
0.633394
93bf75849135e34a811b76ce0a5196c66975f858
2,993
js
JavaScript
src/components/searchBox.js
carlosqsilva/redventures-frontend-test
845d71fef3433126369ed6640a6d34243749de6d
[ "MIT" ]
null
null
null
src/components/searchBox.js
carlosqsilva/redventures-frontend-test
845d71fef3433126369ed6640a6d34243749de6d
[ "MIT" ]
null
null
null
src/components/searchBox.js
carlosqsilva/redventures-frontend-test
845d71fef3433126369ed6640a6d34243749de6d
[ "MIT" ]
null
null
null
import { h, Component } from "preact" import styled from "styled-components" import { inject, observer } from "mobx-preact" import DayPicker, { DateUtils } from "react-day-picker" import { Button } from "./buttons" import Loader from "./loader" @inject("search") @observer export default class SearchBox extends Component { handleClick = day => { const { delimiter, setDelimiter } = this.props.search const range = DateUtils.addDayToRange(day, delimiter) setDelimiter(range) } formatDate = date => { return ( <span> {date.month} <strong>{date.day}</strong>, {date.year} </span> ) } render({ search, action }) { const { from, to } = search.delimiter const modifiers = { start: from, end: to } return ( <Wrapper> <Title>Select the dates to stay in Charlotte</Title> <Container> <Block> <div> <Text primary>CHECK-IN</Text> <Text> {from ? this.formatDate(search.startDate) : "Choose a date"} </Text> </div> <div> <Text primary>CHECK-OUT</Text> <Text> {to ? this.formatDate(search.endDate) : "Choose a date"} </Text> </div> <Button onClick={action}> {search.loading ? <Loader /> : "Search hotels"} </Button> </Block> <Block> <DayPicker className="selection" onDayClick={this.handleClick} selectedDays={[from, { from, to }]} modifiers={modifiers} weekdaysShort={["S", "M", "T", "W", "T", "F", "S"]} disabledDays={[{ before: new Date() }]} /> </Block> </Container> </Wrapper> ) } } const Wrapper = styled.div` background: #fff; margin: -150px 10px 20px 10px; padding: 0 10px; border-radius: 7px; overflow: auto; box-shadow: 0px -40px 46px rgba(0, 0, 0, 0.33); @media screen and (min-width: 720px) { width: 840px; } ` const Title = styled.p` text-align: center; letter-spacing: 1px; font-size: 22px; font-family: "Montserrat"; ` const Container = styled.div` display: flex; flex-direction: column; @media screen and (min-width: 720px) { padding: 40px 80px; flex-direction: initial; } ` const Block = styled.div` display: flex; flex: 1; flex-direction: column; align-items: center; justify-content: space-around; &:first-child { > div { width: 120px; } } @media screen and (max-width: 720px) { flex-direction: initial; justify-content: center; &:first-child { order: 2; flex-wrap: wrap; > div { margin: 10px; } } } ` const Text = styled.p` font-size: ${props => (props.primary ? "22px" : "16px")}; color: ${props => (props.primary ? "rgb(85,85,85)" : "rgb(181,181,181)")}; text-align: left; margin: 0; `
23.566929
76
0.547611
93bf81a05a2704634e91476a082ccfde6198f3d4
1,966
js
JavaScript
lib/commands/LastGame.js
KianParto/9kmmrbot
be989b9c7423beb98cf8bbced8427db8221b0725
[ "MIT" ]
null
null
null
lib/commands/LastGame.js
KianParto/9kmmrbot
be989b9c7423beb98cf8bbced8427db8221b0725
[ "MIT" ]
null
null
null
lib/commands/LastGame.js
KianParto/9kmmrbot
be989b9c7423beb98cf8bbced8427db8221b0725
[ "MIT" ]
null
null
null
'use strict' const { db: mongoDb } = require('../mongo') const Command = require('./Command') const CustomError = require('../CustomError') const util = require('../util') let command = { name: 'Last Game', aliases: ['lg', 'lastgame'], function: async (channel, userstate) => { let accounts = mongoDb().collection('channels').findOne({ id: userstate['room-id'] }, { projection: { accounts: 1, _id: 0 } }) accounts = (await accounts) if (!accounts || !accounts.accounts || !accounts.accounts.length) { return Promise.reject(new CustomError('No accounts connected to ' + channel.substring(1))) } else { accounts = accounts.accounts } let game = await util.findGameFromChannel(userstate['room-id'], false, false) let temp = await mongoDb().collection('last games').find({ lobby_id: { $ne: game.lobby_id.toString() }, 'players.account_id': { $in: accounts } }).sort({ createdAt: -1 }).limit(1).toArray() if (temp && temp.length) { let arr = [] let heroes = mongoDb().collection('heroes').find({ id: { $in: game.players.map(player => player.hero_id.toString()).concat(temp[0].players.map(player => player.hero_id.toString())) } }).toArray() let emoteChannel = mongoDb().collection('settings').findOne({ id: userstate['room-id'], name: 'emotes Channel' }) emoteChannel = await emoteChannel heroes = await heroes game.players.forEach((player, i) => { let tempPlayer = temp[0].players.findIndex(p => p.account_id == player.account_id) if (tempPlayer != -1 && !accounts.includes(temp[0].players[tempPlayer].account_id)) { arr.push(`${util.getHeroName(game, i, heroes, emoteChannel)} played as ${util.getHeroName(temp[0], tempPlayer, heroes, emoteChannel)}`) } }) if (arr.length == 0) { return 'Not playing with anyone from last game' } else { return arr.join(', ') } } else { return Promise.reject(new CustomError('Last match wasn\'t found')) } } } module.exports = [new Command(command)]
49.15
198
0.664802
93bfd21c0aca9aef8af4b664806e8fc1ced80580
555
js
JavaScript
utils/escape-regexp-string.js
stdlib-js/esm
e40d9dc228b49c18a94973ffdfdf4d64e1698d1b
[ "Apache-2.0" ]
12
2020-12-20T20:16:45.000Z
2022-01-30T03:08:18.000Z
utils/escape-regexp-string.js
stdlib-js/esm
e40d9dc228b49c18a94973ffdfdf4d64e1698d1b
[ "Apache-2.0" ]
1
2021-05-24T16:42:11.000Z
2021-05-24T17:51:24.000Z
utils/escape-regexp-string.js
stdlib-js/esm
e40d9dc228b49c18a94973ffdfdf4d64e1698d1b
[ "Apache-2.0" ]
null
null
null
// This file is a part of stdlib. License is Apache-2.0: http://www.apache.org/licenses/LICENSE-2.0 import r from"./../assert/is-string.js";var e=r.isPrimitive,i=/[-\/\\^$*+?.()|[\]{}]/g;function t(r){var t,s;if(!e(r))throw new TypeError("invalid argument. Must provide a regular expression string. Value: `"+r+"`.");if("/"===r[0])for(s=r.length-1;s>=0&&"/"!==r[s];s--);return void 0===s||s<=0?r.replace(i,"\\$&"):(t=(t=r.substring(1,s)).replace(i,"\\$&"),r=r[0]+t+r.substring(s))}var s=t;export default s; //# sourceMappingURL=escape-regexp-string.js.map
185
406
0.628829
93c01867a4d647cea9c1f2f604977a48550247e5
1,013
js
JavaScript
packages/@nucleus/tests/dummy/app/components/nucleus-banner/demo-1.js
mallikarjun1234/nucleus
3e65b7b3c4a71ebf0ce2fd09e2d0a79a75597ecf
[ "MIT" ]
7
2020-08-17T17:47:28.000Z
2021-10-15T21:53:56.000Z
packages/@nucleus/tests/dummy/app/components/nucleus-banner/demo-1.js
mallikarjun1234/nucleus
3e65b7b3c4a71ebf0ce2fd09e2d0a79a75597ecf
[ "MIT" ]
121
2019-10-24T15:44:16.000Z
2020-08-17T07:51:51.000Z
packages/@nucleus/tests/dummy/app/components/nucleus-banner/demo-1.js
mallikarjun1234/nucleus
3e65b7b3c4a71ebf0ce2fd09e2d0a79a75597ecf
[ "MIT" ]
7
2020-01-28T06:45:27.000Z
2020-07-22T10:45:40.000Z
// BEGIN-SNIPPET nucleus-banner.js import Component from '@ember/component'; import { inject } from '@ember/service'; import { get } from '@ember/object' export default Component.extend({ nucleusBanner: inject(), actions: { addItem(type) { const nucleusBanner = get(this, 'nucleusBanner'); nucleusBanner.add({ title: 'Lorem ipsum dolor sit amet chrisy, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua.', type }); }, addItemWithLink(type) { const nucleusBanner = get(this, 'nucleusBanner'); nucleusBanner.add({ title: 'Lorem ipsum dolor sit amet chrisy, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua.', type, isDismissible: true, content: { linkText: "Click here", linkAction: this.testAction.bind(this) } }); } }, testAction() { alert("Undo clicked!"); } }); // END-SNIPPET
30.69697
148
0.638697
93c05e6dad481e67c9f0b146c61f97362cecb5cd
3,605
js
JavaScript
Gruntfile.js
kindratsm/AngularJS-CodeHubGreece
4d0e7ca0e9eb75ad1996aa5ae7e2bece6356ee55
[ "MIT" ]
null
null
null
Gruntfile.js
kindratsm/AngularJS-CodeHubGreece
4d0e7ca0e9eb75ad1996aa5ae7e2bece6356ee55
[ "MIT" ]
null
null
null
Gruntfile.js
kindratsm/AngularJS-CodeHubGreece
4d0e7ca0e9eb75ad1996aa5ae7e2bece6356ee55
[ "MIT" ]
null
null
null
module.exports = function (grunt) { // Project configuration grunt.initConfig({ pkg: grunt.file.readJSON('package.json'), // HTTP server on http://localhost:8000 connect: { 'server': { options: { port: 8000, protocol: 'http', hostname: '127.0.0.1', base: 'src', livereload: true } }, 'server-build': { options: { port: 8001, protocol: 'http', hostname: '127.0.0.1', base: 'build', livereload: true } } }, // check JavaScript files syntax jshint: { files: ['Gruntfile.js', 'src/**/*.js'], options: { esversion: 6, node: true, browser: true } }, // watches watch: { // watch changes in JavaScript files to perform jshint scripts: { files: '**/*.js', tasks: ['jshint'], options: { interrupt: true, }, }, // watch changes in html/js/css files to perform livereload livereload: { files: ['**/*.html', '**/*.js', '**/*.css'], options: { livereload: true } } }, // clean directories clean: { build: ['build/'], temp: ['temp/'] }, uglify: { my_target: { files: { 'build/lib/script.min.js': ['src/lib/*.js'] } } }, // concat and minify CSS cssmin: { target: { files: { 'build/lib/style.min.css': ['src/lib/*.css'] } } }, // copy stream files (images, etc.) copy: { main: { files: [ { expand: true, cwd: 'src/files', src: ['**'], dest: 'build/files' } ], }, }, // process index.html to apply concat and minified js/css files processhtml: { dist: { files: { 'temp/index.html': ['src/index.html'] } } }, // minify index.html htmlmin: { dist: { options: { removeComments: true, collapseWhitespace: true }, files: { 'build/index.html': 'temp/index.html' } } } }); // Load the plugins grunt.loadNpmTasks('grunt-contrib-connect'); grunt.loadNpmTasks('grunt-contrib-jshint'); grunt.loadNpmTasks('grunt-contrib-clean'); grunt.loadNpmTasks('grunt-contrib-uglify-es'); grunt.loadNpmTasks('grunt-contrib-cssmin'); grunt.loadNpmTasks('grunt-contrib-htmlmin'); grunt.loadNpmTasks('grunt-contrib-copy'); grunt.loadNpmTasks('grunt-contrib-watch'); grunt.loadNpmTasks('grunt-processhtml'); // Tasks grunt.registerTask('server', ['connect:server', 'watch']); grunt.registerTask('server-build', ['connect:server-build', 'watch']); grunt.registerTask('build', ['jshint', 'clean', 'uglify', 'cssmin', 'processhtml', 'htmlmin', 'copy', 'clean:temp']); };
30.550847
121
0.409709
93c07824a9f7c467e53eb55056a1358395701861
2,269
js
JavaScript
scripts/type/collection/_PathResolver.js
trujs/TruJS.compile
b3b06f71e6a66edc93e16cc04adf5a8bce830f9e
[ "MIT" ]
null
null
null
scripts/type/collection/_PathResolver.js
trujs/TruJS.compile
b3b06f71e6a66edc93e16cc04adf5a8bce830f9e
[ "MIT" ]
null
null
null
scripts/type/collection/_PathResolver.js
trujs/TruJS.compile
b3b06f71e6a66edc93e16cc04adf5a8bce830f9e
[ "MIT" ]
null
null
null
/** * This factory provides a worker function that resolves either a single path or an * array of paths. * * logic: * 1. ./path/file.js -> single file starting with the base * 2. ./path/* -> all files within path * 3. +./path/* -> all files within path and sub directories within * 4. ./path/*.spec.js -> all files ending with .spec.js * 5. -./path/*.html -> removes all resolved paths * * @factory * @function */ function _PathResolver(promise, type_collection_pathProcessor, type_collection_pathResultProcessor, type_collection_dirProcessor) { /** * * @function */ function resolvePaths(resolve, reject, base, paths) { //get the path object and process any directories promise.all(setupEachPath(base, paths)) .then(function (results) { //process the minus entries in the results results = processResults(results); //resolve the final promise with the updated results resolve(results); }) .catch(function (err) { reject(err); }); } /** * Generate a pathObj for each path and return an array of value/promise * @function */ function setupEachPath(base, paths) { return paths.map(function mapPaths(curPath) { //get the path details var pathObj = type_collection_pathProcessor(base, curPath); //if the pathObj is a directory then list it if (pathObj.directory) { return type_collection_dirProcessor(pathObj); } //otherwise resolve a promise with the path else { return pathObj; } }); } /** * * @function */ function processResults(results) { //create a container for the distinct files var files = []; //loop through the results results.forEach(function forEachResult(result) { files = type_collection_pathResultProcessor(files, result); }); return files; } /** * @worker * @function */ return function PathResolver(base, paths) { //make the paths value an array if (!isArray(paths) && !!paths) { paths = [paths]; } return new promise(function (resolve, reject) { if (!!paths) { resolvePaths(resolve, reject, base, paths); } else { resolve([]); } }); }; }
23.635417
131
0.625386
93c275c1df90eee9d8e80122ef171261e48bdb05
15,460
js
JavaScript
test/flux-rest/flux-rest.spec.js
sebastiencouture/Recurve
8c19cb03eaae2524ba7da02cdcca2971d82b3bb5
[ "MIT" ]
null
null
null
test/flux-rest/flux-rest.spec.js
sebastiencouture/Recurve
8c19cb03eaae2524ba7da02cdcca2971d82b3bb5
[ "MIT" ]
null
null
null
test/flux-rest/flux-rest.spec.js
sebastiencouture/Recurve
8c19cb03eaae2524ba7da02cdcca2971d82b3bb5
[ "MIT" ]
null
null
null
"use strict"; describe("$rest", function() { var $httpProvider; var $rest; var rest; beforeEach(function() { $include(recurve.flux.$module); $include(recurve.flux.rest.$module); $invoke(["$httpProvider", "$rest"], function(httpProvider, restFactory) { $httpProvider = httpProvider; $rest = restFactory; rest = $rest(); }); }); afterEach(function() { $httpProvider.flush(); $httpProvider.verifyExpectations(); $httpProvider.verifyPending(); }); it("should be invokable", function() { expect($rest).toBeDefined(); expect(isFunction($rest)).toEqual(true); }); it("should create rest object", function() { expect(rest).toBeDefined(); expect(isFunction(rest)).toEqual(false); }); describe("resource", function() { it("should create resource with name on rest object", function() { rest.resource("a", "url"); expect(rest.a).toBeDefined(); }); it("it should create default end points: get, save, query and delete", function() { rest.resource("a", "url"); expect(isFunction(rest.a.get)).toEqual(true); expect(isFunction(rest.a.save)).toEqual(true); expect(isFunction(rest.a.query)).toEqual(true); expect(isFunction(rest.a["delete"])).toEqual(true); }); describe("end points", function() { var handler; beforeEach(function() { rest.resource("a", "www.a.com"); }); describe("get", function() { it("should send as http GET method", function() { handler = $httpProvider.on("GET", "www.a.com"); handler.expect(); rest.a.get(); }); it("should return httpPromise object on send", function() { var httpPromise = rest.a.get(); expect(isFunction(httpPromise.then)).toEqual(true); expect(isFunction(httpPromise.success)).toEqual(true); expect(isFunction(httpPromise.error)).toEqual(true); $httpProvider.clearExpectations(); $httpProvider.clearPending(); }); }); describe("save", function() { it("should send as http POST method", function() { handler = $httpProvider.on("POST", "www.a.com"); handler.expect(); rest.a.save(); }); it("should merge second function param as data key into sent http options", function() { handler = $httpProvider.on("POST", "www.a.com"); handler.expect({"data": "a"}); rest.a.save(null, "a"); }); it("should return httpPromise object on send", function() { var httpPromise = rest.a.save(); expect(isFunction(httpPromise.then)).toEqual(true); expect(isFunction(httpPromise.success)).toEqual(true); expect(isFunction(httpPromise.error)).toEqual(true); $httpProvider.clearExpectations(); $httpProvider.clearPending(); }); }); describe("query", function() { it("should send as http GET method", function() { handler = $httpProvider.on("GET", "www.a.com"); handler.expect(); rest.a.query(); }); it("should return httpPromise object on send", function() { var httpPromise = rest.a.query(); expect(isFunction(httpPromise.then)).toEqual(true); expect(isFunction(httpPromise.success)).toEqual(true); expect(isFunction(httpPromise.error)).toEqual(true); $httpProvider.clearExpectations(); $httpProvider.clearPending(); }); }); describe("delete", function() { it("should send as http DELETE method", function() { handler = $httpProvider.on("DELETE", "www.a.com"); handler.expect(); rest.a["delete"](); }); it("should return httpPromise object on send", function() { var httpPromise = rest.a["delete"](); expect(isFunction(httpPromise.then)).toEqual(true); expect(isFunction(httpPromise.success)).toEqual(true); expect(isFunction(httpPromise.error)).toEqual(true); $httpProvider.clearExpectations(); $httpProvider.clearPending(); }); }); describe("additional", function() { beforeEach(function() { rest.resource("a", "www.a.com", null, {custom: {method: "X"}}); }); it("should send as defined http method", function() { handler = $httpProvider.on("X", "www.a.com"); handler.expect(); rest.a.custom(); }); it("should return httpPromise object on send", function() { var httpPromise = rest.a.custom(); expect(isFunction(httpPromise.then)).toEqual(true); expect(isFunction(httpPromise.success)).toEqual(true); expect(isFunction(httpPromise.error)).toEqual(true); $httpProvider.clearExpectations(); $httpProvider.clearPending(); }); }); }); describe("actions", function() { beforeEach(function() { rest.resource("a", "www.a.com"); }); function testActionExistence(method) { expect(rest.a[method].successAction).toBeDefined(); expect(rest.a[method].errorAction).toBeDefined(); expect(rest.a[method].cancelAction).toBeDefined(); } it("should create success, error and cancel actions for get end point", function() { testActionExistence("get"); }); it("should create success, error and cancel actions for save end point", function() { testActionExistence("save"); }); it("should create success, error and cancel actions for query end point", function() { testActionExistence("query"); }); it("should create success, error and cancel actions for delete end point", function() { testActionExistence("delete"); }); describe("trigger", function() { var handler; var successCallback; var errorCallback; var cancelCallback; beforeEach(function() { handler = $httpProvider.on("POST", "www.a.com"); handler.respond({status: 200}); successCallback = jasmine.createSpy("successCallback"); errorCallback = jasmine.createSpy("errorCallback"); cancelCallback = jasmine.createSpy("cancelCallback"); rest.a.save.successAction.on(successCallback); rest.a.save.errorAction.on(errorCallback); rest.a.save.cancelAction.on(cancelCallback); }); it("should only trigger success action on success", function() { rest.a.save(); $httpProvider.flush(); expect(successCallback).toHaveBeenCalled(); expect(errorCallback).not.toHaveBeenCalled(); expect(cancelCallback).not.toHaveBeenCalled(); }); it("should only trigger error action on error", function() { handler.respond({status: 404}); rest.a.save(); $httpProvider.flush(); expect(successCallback).not.toHaveBeenCalled(); expect(errorCallback).toHaveBeenCalled(); expect(cancelCallback).not.toHaveBeenCalled(); }); it("should only trigger cancel action on cancel", function() { var httpPromise = rest.a.save(); httpPromise.cancel(); $httpProvider.flush(); expect(successCallback).not.toHaveBeenCalled(); expect(errorCallback).not.toHaveBeenCalled(); expect(cancelCallback).toHaveBeenCalled(); }); }); }); describe("method params", function() { it("should throw error if no name", function() { expect(function() { rest.resource(); }).toThrowError("expected name to be set"); }); it("should throw error for reserved 'resource' name", function() { expect(function() { rest.resource("resource"); }).toThrowError("resource cannot be named 'resource'"); }); describe("url", function() { var handler; it("should replace named params in url", function() { handler = $httpProvider.on("GET", "www.test.com/1/2/test/3"); handler.expect(); rest.resource("a", "www.test.com/:a/:b/test/:c"); rest.a.get({a: 1, b: 2, c: 3}); }); it("should encode replaced named params in url", function() { handler = $httpProvider.on("GET", "www.test.com/%23/2/test/3"); handler.expect(); rest.resource("a", "www.test.com/:a/:b/test/:c"); rest.a.get({a: "#", b: 2, c: 3}); }); it("should append any other params as query params", function() { handler = $httpProvider.on("GET", "www.test.com/1/2/test/3"); handler.expect({params: {d: 4, e: 5}}); rest.resource("a", "www.test.com/:a/:b/test/:c"); rest.a.get({a: 1, b: 2, c: 3, d: 4, e: 5}); }); it("should strip additional leading slashes from url", function() { handler = $httpProvider.on("GET", "www.test.com"); handler.expect(); rest.resource("a", "//www.test.com"); rest.a.get(); }); it("should strip additional trailing slashes from base url", function() { handler = $httpProvider.on("GET", "www.test.com"); handler.expect(); rest.resource("a", "www.test.com//"); rest.a.get(); }); it("should append resource url to rest config url", function() { handler = $httpProvider.on("GET", "www.test.com/b/c"); handler.expect(); var rest = $rest({url: "www.test.com"}); rest.resource("a", "/b/c"); rest.a.get(); }); it("should add slash between resource url and rest config url if needed", function() { handler = $httpProvider.on("GET", "www.test.com/b/c"); handler.expect(); var rest = $rest({url: "www.test.com"}); rest.resource("a", "b/c"); rest.a.get(); }); it("should strip additional slashes between config and rest resource url", function() { handler = $httpProvider.on("GET", "www.test.com/b/c"); handler.expect(); var rest = $rest({url: "www.test.com/"}); rest.resource("a", "/b/c"); rest.a.get(); }); it("should throw error if no url", function() { expect(function() { rest.resource("a"); }).toThrowError("expected url to be set"); }); }); describe("params", function() { var handler; beforeEach(function() { handler = $httpProvider.on("GET", "www.test.com/b"); }); it("should merge resource default params with config defaults", function() { handler.expect({params: {a: 1, b: 2}}); var rest = $rest({url: "www.test.com", defaults: {params: {a: 1}}}); rest.resource("a", "/b", {b: 2}); rest.a.get(); }); it("should override config defaults with resource default params", function() { handler.expect({params: {a: 2}}); var rest = $rest({url: "www.test.com", defaults: {params: {a: 1}}}); rest.resource("a", "/b", {a: 2}); rest.a.get(); }); it("should merge end point params with resource/rest defaults", function() { handler.expect({params: {a: 1, b: 2, c: 3}}); var rest = $rest({url: "www.test.com", defaults: {params: {a: 1}}}); rest.resource("a", "/b", {b: 2}); rest.a.get({c: 3}); }); it("should override resource/rest defaults with end point params", function() { handler.expect({params: {a: 3}}); var rest = $rest({url: "www.test.com", defaults: {params: {a: 1}}}); rest.resource("a", "/b", {a: 2}); rest.a.get({a: 3}); }); }); it("should include rest config defaults", function() { var handler = $httpProvider.on("GET", "www.test.com/b"); handler.expect({custom: 1}); var rest = $rest({url: "www.test.com", defaults: {custom: 1}}); rest.resource("a", "/b"); rest.a.get(); }); describe("endPoints", function() { var handler; it("should override default end points", function() { rest.resource("a", "www.test.com", null, {save: {method: "X"}}); handler = $httpProvider.on("X", "www.test.com"); handler.expect(); rest.a.save(); }); it("should merge second function param as data into http options", function() { rest.resource("a", "www.test.com", null, {save: {method: "POST"}}); handler = $httpProvider.on("POST", "www.test.com"); handler.expect({data: {a: 1}}); rest.a.save(null, {a: 1}); }); }); }); }); });
38.17284
104
0.465653
93c2c2008d0d823f93132741711e4e40e8708a83
60
js
JavaScript
compat/ie/ws/ws-config.js
rht/ripple-client
5714b739dae1bbe9bbc74c6298250d5a09129f73
[ "0BSD" ]
263
2015-01-08T01:48:20.000Z
2022-01-31T11:23:49.000Z
compat/ie/ws/ws-config.js
rht/ripple-client
5714b739dae1bbe9bbc74c6298250d5a09129f73
[ "0BSD" ]
579
2015-01-03T00:16:09.000Z
2021-11-21T07:36:05.000Z
compat/ie/ws/ws-config.js
rht/ripple-client
5714b739dae1bbe9bbc74c6298250d5a09129f73
[ "0BSD" ]
155
2015-01-09T16:10:53.000Z
2022-01-10T20:37:45.000Z
WEB_SOCKET_SWF_LOCATION = "compat/ie/ws/WebSocketMain.swf";
30
59
0.816667
93c3de3c495ad89425a605e20f57f60fe0e961e5
89
js
JavaScript
examples/element/src/service/login.js
niexiaofei1988/all_demos
d43fc1b289be00b9dedcc69d0832155b91ee1b9f
[ "MIT" ]
null
null
null
examples/element/src/service/login.js
niexiaofei1988/all_demos
d43fc1b289be00b9dedcc69d0832155b91ee1b9f
[ "MIT" ]
12
2020-01-21T05:11:00.000Z
2021-03-10T09:29:02.000Z
examples/element/src/service/login.js
niexiaofei1988/learning
d43fc1b289be00b9dedcc69d0832155b91ee1b9f
[ "MIT" ]
null
null
null
/** * @name * @description: 登录, 退出, 注册 */ export default { login: '/login.json', }
9.888889
27
0.539326
93c550532bb308f2cf6f553ee00091d11392e210
591
js
JavaScript
global/breadcrumb.js
cjb1979/cjb1979.github.io
f5a6fac7060b1ca7773ed0f07ab55cc9bb85f508
[ "MIT" ]
1
2018-02-27T16:56:15.000Z
2018-02-27T16:56:15.000Z
global/breadcrumb.js
cjb1979/cjb1979.github.io
f5a6fac7060b1ca7773ed0f07ab55cc9bb85f508
[ "MIT" ]
null
null
null
global/breadcrumb.js
cjb1979/cjb1979.github.io
f5a6fac7060b1ca7773ed0f07ab55cc9bb85f508
[ "MIT" ]
null
null
null
const breadcrumb = ((path = window.location.pathname) => { const upper = (text) => text.replace(/^\w/, c => c.toUpperCase()); const home = 'CJ Boyd'; let arr = path.split("/"); arr[0] = home; arr = arr.filter(x => x); return ((arr) => { const html_arr = arr.map((x, i, arr) => { const link_text = upper(x); const link_url = "/" + arr.slice(1, i + 1).join("/"); return i === arr.length - 1 ? link_text : `<a href = "${link_url}">${link_text}</a>`; }); return html_arr.join(" / "); })(arr); })(); $(() => $('#breadcrumb').html(breadcrumb));
26.863636
91
0.519459
93c82ec7ee33cbda27c8f0e8aeb3b64d8be56a20
1,085
js
JavaScript
react-client/src/containers/news/edit.js
uzubtsou/LiquidRecipes
0452ac8e931bec4a5fea4ea8416fc27978d82511
[ "MIT" ]
7
2017-08-08T18:45:09.000Z
2018-06-10T17:47:50.000Z
react-client/src/containers/news/edit.js
uzubtsou/LiquidRecipes
0452ac8e931bec4a5fea4ea8416fc27978d82511
[ "MIT" ]
7
2021-03-01T22:18:08.000Z
2022-03-08T22:36:44.000Z
react-client/src/containers/news/edit.js
uzubtsou/LiquidRecipes
0452ac8e931bec4a5fea4ea8416fc27978d82511
[ "MIT" ]
5
2017-08-08T18:45:58.000Z
2020-05-11T09:38:49.000Z
import React, { Component } from "react"; import { bindActionCreators } from "redux"; import { connect } from "react-redux"; import {NewsFormComponent} from "../../components/index"; import {updateSingleNews} from "../../modules/news/actions"; import {selectSingleNewsData} from "../../modules/news/selectors"; class NewsEditContainer extends Component { checkAndSend(data) { console.log(data); // this.props.actions.createNewsSingle(data); } render() { return ( <div className="container content"> <div className="text-center"> <h3>Create new news</h3> <div className="row"> <NewsFormComponent onSubmit={this.checkAndSend.bind(this)} news={this.props.singleNews} /> </div> </div> </div> ) } } export const NewsEdit = connect( (state, props) => ({ singleNews: selectSingleNewsData(state, props.match.params.id) }), (dispatch) => ({ actions: bindActionCreators({ updateSingleNews }, dispatch) }) )(NewsEditContainer);
23.586957
66
0.614747
93cb019992ab87f613b254c93ab8793b8b249530
1,110
js
JavaScript
elements/lrndesign-stepper/lrndesign-stepper.es6.js
cgldevel/lrnwebcomponents
b301e58b042b606ab6378bdaae24ac537bfc0c0e
[ "Apache-2.0" ]
null
null
null
elements/lrndesign-stepper/lrndesign-stepper.es6.js
cgldevel/lrnwebcomponents
b301e58b042b606ab6378bdaae24ac537bfc0c0e
[ "Apache-2.0" ]
null
null
null
elements/lrndesign-stepper/lrndesign-stepper.es6.js
cgldevel/lrnwebcomponents
b301e58b042b606ab6378bdaae24ac537bfc0c0e
[ "Apache-2.0" ]
null
null
null
/** * Copyright 2018 The Pennsylvania State University * @license Apache-2.0, see License.md for full text. */import{html,PolymerElement}from"./node_modules/@polymer/polymer/polymer-element.js";/** `lrndesign-stepper` visualization of steps * @demo demo/index.html */class LrndesignStepper extends PolymerElement{constructor(){super();import("./node_modules/@lrnwebcomponents/lrndesign-stepper/lib/lrndesign-stepper-button.js")}static get template(){return html` <style> :host { display: block; } </style> <div class="buttons"><slot id="stepper-children"> </slot></div> `}static get tag(){return"lrndesign-stepper"}ready(){super.ready();var root=this,children=root.getContentChildren("#stepper-children");if(1<children.length){children.forEach(function(child,index){if(0===index){child.setAttribute("location","start")}else if(index===children.length-1){child.setAttribute("location","end")}else{child.setAttribute("location","middle")}console.log(child,index)})}}}window.customElements.define(LrndesignStepper.tag,LrndesignStepper);export{LrndesignStepper};
69.375
492
0.738739
93cbecb7e95c35c941e0da6875ead7ed0fc3d217
837
js
JavaScript
index.js
paul-lrr/nifty-recognizer
5e7e45f888abf3db93ac32b2937d571497b8fbaa
[ "MIT" ]
28
2016-09-21T19:32:16.000Z
2021-09-29T12:13:25.000Z
index.js
paul-lrr/nifty-recognizer
5e7e45f888abf3db93ac32b2937d571497b8fbaa
[ "MIT" ]
7
2016-09-24T16:24:54.000Z
2021-09-20T19:06:23.000Z
index.js
paul-lrr/nifty-recognizer
5e7e45f888abf3db93ac32b2937d571497b8fbaa
[ "MIT" ]
6
2016-09-24T17:18:43.000Z
2020-05-05T11:21:11.000Z
var express = require('express'); var app = express(); var server = require('http').Server(app); var io = require('socket.io').listen(server); app.use(express.static('public')); server.listen(80, function () { console.log('Nifty server running on port 80!'); }); io.set('transports', ['websocket']); io.on('connection', function (socket) { app.get('/cardmatch/:id', function (req, res) { res.send(req.params.id); if(isNaN(req.params.id)){ socket.broadcast.emit('card_image', {'auto':true,'src':'http://localhost/cards/'+req.params.id+'.jpg'}); } else { socket.broadcast.emit('card_image', {'auto':true,'src':'http://gatherer.wizards.com/Handlers/Image.ashx?multiverseid='+req.params.id+'&type=card'}); } }); socket.on('card_image', function(msg){ socket.broadcast.emit('card_image', msg); }); });
27
151
0.653524
93cc5abc7472929dd69d9e5c339983c42a9033d0
32,012
js
JavaScript
Client/my-liquor/src/containers/Questions.js
mukeshmohanty4708/LiquorLicensor
b1c2ad24c85fea34cce2263c6270bdf7dbb65824
[ "Unlicense" ]
null
null
null
Client/my-liquor/src/containers/Questions.js
mukeshmohanty4708/LiquorLicensor
b1c2ad24c85fea34cce2263c6270bdf7dbb65824
[ "Unlicense" ]
null
null
null
Client/my-liquor/src/containers/Questions.js
mukeshmohanty4708/LiquorLicensor
b1c2ad24c85fea34cce2263c6270bdf7dbb65824
[ "Unlicense" ]
null
null
null
import React, { Component } from 'react' import './questions.css' import { Dropdown } from 'primereact/dropdown'; import { Button } from 'primereact/button'; import { ListBox } from 'primereact/listbox'; import { Toast } from 'primereact/toast'; import { InputTextarea } from 'primereact/inputtextarea'; import { DataTable } from 'primereact/datatable'; import { Column } from 'primereact/column'; import { InputSwitch } from 'primereact/inputswitch'; import { Calendar } from 'primereact/calendar'; import { InputText } from 'primereact/inputtext'; export default class Questions extends Component { constructor(props) { super(props) this.state = { selectedstate: null, selectedcounty: null, loading: false, ispremisevisible: true, cityvalue: null, query_created: null, restuarantdata: [], first: 0, rows: 10, zipvalue: null, zonevalue: null, citychecked: false, zipchecked: false, zonechecked: false, //Operation variables isoperationvisible: true, methodoperationvalue: null, methodoperationcheck: false, licensecodecheck: false, licensecodevalue: null, countychecked: false, //License dates islicenseinfovisible: true, dateframecheck: false, dateissuevalue: null, dateexpryvalue: null, recentstartdatevalue: null, //alcoholinfo isalcoholinfovisible: true, alcoholcheck: false, alcoholselected: null, alcoholtypes: null } this.countylist = []; this.city = []; this.zip = []; this.zone = []; this.methodoperation = []; this.licensecode = []; // this.references = ['NY', 'CA', 'WA', 'VA', 'MI', 'OR', 'CO', 'NJ', 'ID', 'TX', 'NC', // 'VT', 'WI', 'PA', 'GA', 'MD', 'TN', 'AZ', 'MA', 'NM', 'MO', 'HI', // 'SD', 'MT', 'CT', 'FL', 'OH', 'MN', 'IN', 'IL', // 'WY']; this.references = ['NY', 'CA']; this.onStateChange = this.onStateChange.bind(this); this.onCountyChange = this.onCountyChange.bind(this); this.onLoadingClick = this.onLoadingClick.bind(this); this.onResetClick = this.onResetClick.bind(this); this.onSaveClick = this.onSaveClick.bind(this); this.onCustomPage2 = this.onCustomPage2.bind(this); this.onCityChange = this.onCityChange.bind(this); this.onZipChange = this.onZipChange.bind(this); this.onZoneChange = this.onZoneChange.bind(this); this.onMethodOperationChange = this.onMethodOperationChange.bind(this); this.onLicenseCodeChange = this.onLicenseCodeChange.bind(this); } onStateChange = (e) =>{ this.setState({ selectedstate: e.target.value }); } onResetClick = (e) =>{ e.preventDefault(); this.setState({ // selectedstate: null, selectedcounty: null, loading: false, ispremisevisible: true, query_created: null, restuarantdata: [], cityvalue: null, zipvalue: null, zonevalue: null, citychecked: false, zipchecked: false, zonechecked: false, methodoperationcheck: false, methodoperationvalue: null, licensecodecheck: false, licensecodevalue: null, dateframecheck: false, dateexpryvalue: null, dateissuevalue: null, recentstartdatecheck: false, alcoholcheck: false, countychecked: false, countylist: null }) if(this.state.selectedstate === null) return; const req_data = { state_name: (this.state.selectedstate === null) ? null : this.state.selectedstate, } this.getQueryResultLoad(req_data); this.toast.show({severity:'info', summary: 'Sucessfully Cleared the Entries', life: 3000}); } onSaveClick = (e) =>{ e.preventDefault(); if(this.state.restuarantdata.length === 0) { alert('No Records Avaiable, would you like to change your conditions?'); return; } //Code to post the data to the user profile db var req_data ={ sql_query : this.state.query_created, date_time : Date().toLocaleString(), user : localStorage.getItem('username'), }; var req = new Request('http://localhost:4000/pgresms/validate/saved_preferences', { method: 'POST', headers: new Headers({ 'Content-Type': 'application/json' }), body: JSON.stringify(req_data) }); fetch(req) .then((res)=>{ if(res.status === 400) throw new Error(res.statusText); res.json().then((data)=>{ this.toast.show({severity:'success', summary: data.message, life: 3000}); }) }) .catch((err)=>{ console.log(err) this.toast.show({severity:'error', summary: 'Error Message', detail:err.message, life: 3000}); }) } // Button Loading Code onLoadingClick = (e) => { e.preventDefault(); this.setState({ loading: true }); setTimeout(() => { this.setState({ loading: false }); }, 2000); const req_data = { state_name: (this.state.selectedstate === null) ? null : this.state.selectedstate } console.log(req_data) this.getQueryResultLoad(req_data); } getQueryResultLoad = (req_data) =>{ console.log('In getQueryResult'); var req = new Request('http://localhost:4000/pgresms/validate/question_query_load', { method: 'POST', headers: new Headers({ 'Content-Type': 'application/json' }), body: JSON.stringify(req_data) }); fetch(req) .then((res)=>{ if(res.status === 400) throw new Error(res.statusText); res.json().then((data)=>{ this.setState({ ispremisevisible: true, query_created: data.query, restuarantdata: data.tbl}) console.log(data.tbl); this.toast.show({severity:'success', summary: 'Sucessfully retrieved Data from Server', life: 3000}); }) }) .catch((err)=>{ console.log(err) this.toast.show({severity:'error', summary: 'Error Message', detail:err.message, life: 3000}); }) } onCityChange = (e) =>{ if(this.state.selectedstate === null) return; e.preventDefault(); if(e.value){ //compute the this.methodoperation var api_link = 'http://localhost:4000/pgresms/validate/question_query_city_name'; var req = new Request(api_link, { method: 'POST', headers: new Headers({ 'Content-Type': 'application/json' }), body: JSON.stringify({state_name: this.state.selectedstate}) }); fetch(req) .then((res)=>{ if(res.status === 400) throw new Error(); res.json().then((data)=>{ data.tbl.forEach(element => { this.city.push({name: element.city_name}); }); }) }) .catch((err)=>{ console.log(err) }) } this.setState({citychecked: e.value, cityvalue: null}) } onZipChange = (e) =>{ if(this.state.selectedstate === null) return; e.preventDefault(); if(e.value){ //compute the this.methodoperation var api_link = 'http://localhost:4000/pgresms/validate/question_query_zip_name'; var req = new Request(api_link, { method: 'POST', headers: new Headers({ 'Content-Type': 'application/json' }), body: JSON.stringify({state_name: this.state.selectedstate}) }); fetch(req) .then((res)=>{ if(res.status === 400) throw new Error(); res.json().then((data)=>{ data.tbl.forEach(element => { this.zip.push({name: element.zip}); }); }) }) .catch((err)=>{ console.log(err) }) } this.setState({zipchecked: e.value, zipvalue: null}) } onZoneChange = (e) =>{ if(this.state.selectedstate === null) return; e.preventDefault(); if(e.value){ //compute the this.methodoperation var api_link = 'http://localhost:4000/pgresms/get/question_query_zone_code'; fetch(api_link) .then((res)=>{ if(res.status === 400) throw new Error(); res.json().then((data)=>{ data.tbl.forEach(element => { this.zone.push({name: element.zone_name}); }); }) }) .catch((err)=>{ console.log(err) }) } this.setState({zonechecked: e.value, zonevalue: null}) } onSubmitClick = (e) => { e.preventDefault(); this.setState({ loading: true }); setTimeout(() => { this.setState({ loading: false }); }, 2000); const req_data = { state_name: (this.state.selectedstate === null) ? null : this.state.selectedstate, county_name: (this.state.selectedcounty === null) ? null : this.state.selectedcounty.name, city_name: (this.state.cityvalue === null) ? null : this.state.cityvalue.name, zip_code: (this.state.zipvalue === null) ? null : this.state.zipvalue.name, zone_name: (this.state.zonevalue === null) ? null : this.state.zonevalue.name, m_operation: (this.state.methodoperationvalue === null) ? null : this.state.methodoperationvalue.name, license_code: (this.state.licensecodevalue === null) ? null : this.state.licensecodevalue.name, issue_date: (this.state.dateissuevalue === null) ? null : this.state.dateissuevalue, expiry_date: (this.state.dateexpryvalue === null) ? null : this.state.dateexpryvalue, recent_start_date: (this.state.recentstartdatevalue === null) ? null : this.state.recentstartdatevalue, } console.log(req_data) this.getQueryResultSubmit(req_data); } getQueryResultSubmit = (req_data) =>{ console.log('In getQuerySubmit'); var req = new Request('http://localhost:4000/pgresms/validate/question_query_submit', { method: 'POST', headers: new Headers({ 'Content-Type': 'application/json' }), body: JSON.stringify(req_data) }); fetch(req) .then((res)=>{ if(res.status === 400) throw new Error(res.statusText); res.json().then((data)=>{ this.setState({ ispremisevisible: true, query_created: data.query, restuarantdata: data.tbl}) this.loadWineOptionsData(data.tbl); this.toast.show({severity:'success', summary: 'Sucessfully Retrieved Data from Server', life: 3000}); }) }) .catch((err)=>{ console.log(err) this.toast.show({severity:'error', summary: 'Error Message', detail:err.message, life: 3000}); }) } loadWineOptionsData(options){ if(options === undefined || options.length === 0){ this.setState({alcoholtypes : null, alcoholcheck: true}) return;} console.log('loadWineOptionsData: premise obj') var premise_obj = [] options.forEach((row)=>{ premise_obj.push(row.premise_name); }) console.log('premise_obj') console.log(premise_obj) var req = new Request('http://localhost:4000/mgservices/api/mg/getWineList', { method: 'POST', headers: new Headers({ 'Content-Type': 'application/json' }), body: JSON.stringify({id: premise_obj}) }); console.log('http://localhost:4000/mgservices/api/mg/getWineList') let arr_data = []; let map_data = []; fetch(req) .then((res)=>{ res.json().then(data=>{ console.log(data) data.forEach((row)=>{ if(map_data.indexOf(row.Wholesaler_Name) === -1){ arr_data.push(row); map_data.push(row.Wholesaler_Name); } }) this.setState({alcoholtypes : arr_data, alcoholcheck: true}) }) }) .catch((err)=>{ console.log(err) this.toast.show({severity:'error', summary: 'Error Message', detail:err.message, life: 3000}); }) } //Table pagination functions onCustomPage2 = (event) => { this.setState({ first: event.first, rows: event.rows }); } onMethodOperationChange = (e) =>{ if(this.state.selectedstate === null) return; e.preventDefault(); console.log("Inside the onMethodOperationChange: " + e.value) if(e.value){ //compute the this.methodoperation var api_link = 'http://localhost:4000/pgresms/validate/question_query_method_operation'; var req = new Request(api_link, { method: 'POST', headers: new Headers({ 'Content-Type': 'application/json' }), body: JSON.stringify({state_name: this.state.selectedstate}) }); fetch(req) .then((res)=>{ if(res.status === 400) throw new Error(); res.json().then((data)=>{ console.log(data); // this.methodoperation = []; data.tbl.forEach(element => { this.methodoperation.push({name: element.method_of_operation}); }); }) }) .catch((err)=>{ console.log(err) }) } this.setState({methodoperationcheck: e.value, methodoperationvalue: null}) return; } onLicenseCodeChange = (e) =>{ if(this.state.selectedstate === null) return; this.licensecode = []; e.preventDefault(); if(e.value){ var api_link = 'http://localhost:4000/pgresms/validate/question_query_license_code'; var req = new Request(api_link, { method: 'POST', headers: new Headers({ 'Content-Type': 'application/json' }), body: JSON.stringify({state_name: this.state.selectedstate}) }); fetch(req) .then((res)=>{ if(res.status === 400) throw new Error(); res.json().then((data)=>{ console.log(data); data.tbl.forEach(element => { this.licensecode.push({name: element.license_type_code}); }); }) }) .catch((err)=>{ console.log(err) }) } this.setState({licensecodecheck: e.value, licensecodevalue: null}) return; } onCountyChange = (e) =>{ if(this.state.selectedstate === null) return; e.preventDefault(); if(e.value){ var req = new Request('http://localhost:4000/pgresms/validate/getcounty_records', { method: 'POST', headers: new Headers({ 'Content-Type': 'application/json' }), body: JSON.stringify({state_name: this.state.selectedstate}) }); fetch(req) .then((res)=>{ if(res.status === 400) throw new Error(res.statusText); res.json().then((data)=>{ console.log(data); // this.countylist = []; data.tbl.forEach((row,i)=>{ this.countylist.push({name: row.county}); }) }) }) .catch((err)=>{ console.log(err) this.toast.show({severity:'error', summary: 'Error Message', detail:err.message, life: 3000}); }) } this.setState({countychecked: e.value, selectedcounty: null}) return; } onDateframeChange = (e)=>{ if(this.state.selectedstate === null) return; e.preventDefault(); this.setState({dateframecheck: e.value, dateissuevalue: null, dateexpryvalue: null}) } onStartDateChange = (e) =>{ if(this.state.selectedstate === null) return; e.preventDefault(); this.setState({recentstartdatecheck: e.value, recentstartdatevalue: null }) } monthNavigatorTemplate(e) { return <Dropdown value={e.value} options={e.options} onChange={(event) => e.onChange(event.originalEvent, event.value)} style={{ lineHeight: 1 }} />; } yearNavigatorTemplate(e) { return <Dropdown value={e.value} options={e.options} onChange={(event) => e.onChange(event.originalEvent, event.value)} className="p-ml-2" style={{ lineHeight: 1 }} />; } onAlcoholChange = (e) =>{ e.preventDefault(); this.setState({alcoholcheck: e.value}) } alcoholTemplate = (option) =>{ if(option === undefined || option === null) { this.setState({alcoholcheck:false}) return;} console.log(option); return( <ul className='list_al-container'> {option.map((ele) => ( <li>{ele.Product_Description}</li> ) )} </ul> ) } printReferences(){ // console.log(this.references); return(this.references.map((ele)=>{ return( <span> {ele}{','} </span> ) })) } render() { //Table Pagination Handle const template2 = { layout: 'RowsPerPageDropdown CurrentPageReport PrevPageLink NextPageLink', 'RowsPerPageDropdown': (options) => { const dropdownOptions = [ { label: 10, value: 10 }, { label: 20, value: 20 }, { label: 50, value: 50 } ]; return ( <React.Fragment> <span className="p-mx-1" style={{ color: 'var(--text-color)', userSelect: 'none' }}>Items per page: </span> <Dropdown value={options.value} options={dropdownOptions} onChange={options.onChange} appendTo={document.body} /> </React.Fragment> ); }, 'CurrentPageReport': (options) => { return ( <span style={{ color: 'var(--text-color)', userSelect: 'none', width: '120px', textAlign: 'center' }}> {options.first} - {options.last} of {options.totalRecords} </span> ) } }; return ( <div className='container-question'> <div>Find a Licensor for your New Business</div> <Toast ref={(el) => this.toast = el} /> <div className='query-maker'> <div className='container-countystate'> <span className='drop-card'> <h3>Select the STATE</h3> {/* <Dropdown value={this.state.selectedstate} options={this.statelist} onChange={this.onStateChange} optionLabel="name" placeholder="State" style={{ width: '15rem' }}/> */} <InputText value={this.state.selectedstate} onChange={this.onStateChange} style={{ width: '15rem' }}/> </span> <span className='container-countystate-btn'> <Button className="countystate-btn p-button-raised p-button-text" label="Load Data" onClick={(e) => this.onLoadingClick(e)} style={{'color' : 'white', 'background': 'lightcoral'}}/> </span> <span>References : </span> <span style={{'color':'cadetblue'}}>{this.printReferences()}</span> </div> <div className='container-query-cards'> <div className='container-premise'> { (this.state.ispremisevisible) ? <div> <div> <h4>Do you want to search by City Name?</h4> <InputSwitch checked={this.state.citychecked} onChange={(e)=>this.onCityChange(e)} /> {this.state.citychecked ? <Dropdown value={this.state.cityvalue} options={this.city} onChange={(e) => this.setState({ cityvalue: e.value })} optionLabel="name" placeholder="Select a City" style={{ width: '15rem' }} /> : null } </div> <div> <h4>Do you want to search by Zip Code?</h4> <InputSwitch checked={this.state.zipchecked} onChange={(e)=>this.onZipChange(e)} /> {this.state.zipchecked ? <Dropdown value={this.state.zipvalue} options={this.zip} onChange={(e) => this.setState({ zipvalue: e.value })} optionLabel="name" placeholder="Select a Zip" style={{ width: '15rem' }} /> : null } </div> <div> <h4>Do you want to search by available Zone?</h4> <InputSwitch checked={this.state.zonechecked} onChange={(e)=>this.onZoneChange(e)} /> {this.state.zonechecked ? <Dropdown value={this.state.zonevalue} options={this.zone} onChange={(e) => this.setState({ zonevalue: e.value })} optionLabel="name" placeholder="Select a Zone" style={{ width: '15rem' }} /> : null } </div> </div> : null } </div> <div className='container-operation'> { (this.state.isoperationvisible) ? <div> <div> <h4>Choose by Method Of Operation<i>(by wine seller type)</i>?</h4> <InputSwitch checked={this.state.methodoperationcheck} onChange={(e)=>this.onMethodOperationChange(e)} /> {this.state.methodoperationcheck ? <Dropdown className='method-dropdwn' value={this.state.methodoperationvalue} options={this.methodoperation} onChange={(e) => this.setState({ methodoperationvalue: e.value })} optionLabel="name" placeholder="Select a Operation" style={{ width: '15rem' }} /> : null } </div> <div> <h4>Choose License Code?</h4> <InputSwitch checked={this.state.licensecodecheck} onChange={(e)=>this.onLicenseCodeChange(e)} /> {this.state.licensecodecheck ? <Dropdown className='method-dropdwn' value={this.state.licensecodevalue} options={this.licensecode} onChange={(e) => this.setState({ licensecodevalue: e.value })} optionLabel="name" placeholder="Select a Code" style={{ width: '15rem' }} /> : null } </div> <div> <h4>Do you want to search by County?</h4> <InputSwitch checked={this.state.countychecked} onChange={(e)=>this.onCountyChange(e)} /> {this.state.countychecked ? <Dropdown className='method-dropdwn' value={this.state.selectedcounty} options={this.countylist} onChange={(e) => this.setState({ selectedcounty: e.value })} optionLabel="name" placeholder="County" style={{ width: '15rem' }} /> : null } </div> </div> : null } </div> <div className='container-licenseinfo'> { (this.state.islicenseinfovisible) ? <div> <div> <h4>Choose by Issued Expiry License Range?</h4> <InputSwitch checked={this.state.dateframecheck} onChange={(e)=>this.onDateframeChange(e)} /> {this.state.dateframecheck ? <div> <Calendar id="navigatorstemplate" value={this.state.dateissuevalue} onChange={(e) => this.setState({ dateissuevalue: e.value })} monthNavigator yearNavigator yearRange="2010:2030" monthNavigatorTemplate={this.monthNavigatorTemplate} yearNavigatorTemplate={this.yearNavigatorTemplate} /> <Calendar id="navigatorstemplate" value={this.state.dateexpryvalue} onChange={(e) => this.setState({ dateexpryvalue: e.value })} monthNavigator yearNavigator yearRange="2010:2030" monthNavigatorTemplate={this.monthNavigatorTemplate} yearNavigatorTemplate={this.yearNavigatorTemplate} /> </div> : null } </div> <div> <h4>Choose by Recent Start License Date(<i>ge</i>)?</h4> <InputSwitch checked={this.state.recentstartdatecheck} onChange={(e)=>this.onStartDateChange(e)} /> {this.state.recentstartdatecheck ? <Calendar id="navigatorstemplate" value={this.state.recentstartdatevalue} onChange={(e) => this.setState({ recentstartdatevalue: e.value })} monthNavigator yearNavigator yearRange="2010:2030" monthNavigatorTemplate={this.monthNavigatorTemplate} yearNavigatorTemplate={this.yearNavigatorTemplate} /> : null } </div> </div> : null } </div> <div className='container-alcoholinfo'> {this.state.isalcoholinfovisible ? <div> <h4>OPTIONS Available <i>(for you)</i></h4> <InputSwitch checked={this.state.alcoholcheck} onChange={(e)=>this.onAlcoholChange(e)} /> {this.state.alcoholcheck ? this.alcoholTemplate(this.state.alcoholtypes) : <h4>No Data Available</h4> } </div> : <h4>No Data Available</h4> } </div> </div> <div className='btn-set'> <Button label="Submit" loading={this.state.loading} onClick={(e) => this.onSubmitClick(e)} /> <Button label="Reset" onClick={(e) => this.onResetClick(e)} /> <Button label="Save Preferences" onClick={(e) => this.onSaveClick(e)} /> </div> </div> <div className='query-contianer'> { (this.state.query_created !== null)? <InputTextarea value={this.state.query_created.text} rows={5} cols={130} disabled /> : <InputTextarea value={'Query formulated for the conditions'} rows={5} cols={130} disabled /> } </div> <div className='result-contianer'> <DataTable value={this.state.restuarantdata} paginator paginatorTemplate={template2} first={this.state.first} rows={this.state.rows} onPage={this.onCustomPage2} responsiveLayout="scroll" paginatorClassName="p-jc-end" className="p-mt-6" > <Column field="premise_name" header="Active License Holder" sortable></Column> <Column field="premise_addr" header="Address" sortable></Column> <Column field="state_name" header="State" sortable></Column> </DataTable> </div> </div> ) } }
41.520104
296
0.464951
93cce48ecef5e9a474c79cb205af8ae2b772c64b
1,683
js
JavaScript
NMRangeSliderIOS.js
Enrise/react-native-nmrangeslider-ios
6a08042e76989fb9de5f9d82fffcabbeabe10448
[ "MIT" ]
38
2016-02-05T12:49:43.000Z
2021-07-03T22:38:04.000Z
NMRangeSliderIOS.js
Enrise/react-native-nmrangeslider-ios
6a08042e76989fb9de5f9d82fffcabbeabe10448
[ "MIT" ]
9
2016-02-15T07:41:08.000Z
2018-05-23T08:04:22.000Z
NMRangeSliderIOS.js
Enrise/react-native-nmrangeslider-ios
6a08042e76989fb9de5f9d82fffcabbeabe10448
[ "MIT" ]
10
2016-02-22T14:49:23.000Z
2018-12-07T09:55:28.000Z
import React, { Text, ColorPropType } from 'react-native'; const requireNativeComponent = require('react-native').requireNativeComponent; const NMRangeSliderIOS = React.createClass({ propTypes: { minimumValue: React.PropTypes.number, maximumValue: React.PropTypes.number, lowerValue: React.PropTypes.number, lowerMaximumValue: React.PropTypes.number, upperValue: React.PropTypes.number, upperMinimumValue: React.PropTypes.number, minimumRange: React.PropTypes.number, stepValue: React.PropTypes.number, stepValueContinuously: React.PropTypes.bool, continuous: React.PropTypes.bool, lowerCenter: React.PropTypes.object, // CGPoint? upperCenter: React.PropTypes.object, // CGPoint? onChange: React.PropTypes.func, trackColor: ColorPropType, disabled: React.PropTypes.bool, }, componentDidMount() { this.setState({...this.props}); }, componentWillReceiveProps(nextProps) { this.setState(nextProps); }, convertNativeEvent(event) { return [ parseInt(event.nativeEvent.lowerValue, 10), parseInt(event.nativeEvent.upperValue, 10), ]; }, _onChange: function(event) { if (!this.props.onChange) { return; } this.props.onChange(this.convertNativeEvent(event)); }, render: function() { return ( <NMRangeSlider {...this.props} lowerValue={0} upperValue={0} disabled={false} {...this.state} onChange={this._onChange} /> ) } }); const NMRangeSlider = requireNativeComponent('NMRangeSlider', NMRangeSliderIOS, { nativeOnly: { onChange: true, }, }); module.exports = NMRangeSliderIOS;
25.5
81
0.680333
93ccf9db2892ef8b345e7fdaf3a328d6773398f8
736
js
JavaScript
plugins/cache.js
jorinvo/js-graphic-designer
269ed081ed6283445fd3631976fa27065fbd2174
[ "MIT" ]
null
null
null
plugins/cache.js
jorinvo/js-graphic-designer
269ed081ed6283445fd3631976fa27065fbd2174
[ "MIT" ]
1
2015-01-26T22:01:13.000Z
2015-01-26T22:01:13.000Z
plugins/cache.js
jorinvo/js-graphic-designer
269ed081ed6283445fd3631976fa27065fbd2174
[ "MIT" ]
null
null
null
var defaults = { storageKey: 'graphicDesignerGraphic' }; var cache = function(app, options) { var loadFromCache = function() { var backup = localStorage.getItem(options.storageKey); if (!backup) return; app.container.innerHTML = backup; app.svg = app.container.querySelector('svg'); app.emit('svg:load'); }; var updateCache = function() { localStorage.setItem(options.storageKey, app.container.innerHTML); app.emit('cache:change'); }; app .on('ready', loadFromCache) .on('element', updateCache) .on('svg:resize', updateCache) .on('background', updateCache); }; cache.defaults = defaults; module.exports = cache;
20.444444
74
0.612772
93d22be0001c7c65deaa75db01fb6b202ef4dd30
1,887
js
JavaScript
day-19-monster-messages/test.js
mariotacke/advent-of-code-2020
7fe66a7b1861d02cc3d99e03c6e8fa6c2177782e
[ "MIT" ]
11
2020-12-02T21:13:45.000Z
2021-12-04T06:16:30.000Z
day-19-monster-messages/test.js
mariotacke/advent-of-code-2020
7fe66a7b1861d02cc3d99e03c6e8fa6c2177782e
[ "MIT" ]
3
2021-11-23T18:22:22.000Z
2021-11-23T18:23:00.000Z
day-19-monster-messages/test.js
mariotacke/advent-of-code-2020
7fe66a7b1861d02cc3d99e03c6e8fa6c2177782e
[ "MIT" ]
2
2020-12-05T03:50:34.000Z
2021-02-24T22:18:39.000Z
const assert = require('assert'); const message = require('./message'); const message2 = require('./message2'); describe('Day 19: Monster Messages', () => { it('should validate messages', () => { const input = `0: 4 1 5 1: 2 3 | 3 2 2: 4 4 | 5 5 3: 4 5 | 5 4 4: "a" 5: "b" ababbb bababa abbbab aaabbb aaaabbb`; assert.strictEqual(message(input), 2); }); describe('Part Two', () => { it('should validate messages with loops', () => { const input = `42: 9 14 | 10 1 9: 14 27 | 1 26 10: 23 14 | 28 1 1: "a" 11: 42 31 5: 1 14 | 15 1 19: 14 1 | 14 14 12: 24 14 | 19 1 16: 15 1 | 14 14 31: 14 17 | 1 13 6: 14 14 | 1 14 2: 1 24 | 14 4 0: 8 11 13: 14 3 | 1 12 15: 1 | 14 17: 14 2 | 1 7 23: 25 1 | 22 14 28: 16 1 4: 1 1 20: 14 14 | 1 15 3: 5 14 | 16 1 27: 1 6 | 14 18 14: "b" 21: 14 1 | 1 14 25: 1 1 | 1 14 22: 14 14 8: 42 26: 14 22 | 1 20 18: 15 15 7: 14 5 | 1 21 24: 14 1 abbbbbabbbaaaababbaabbbbabababbbabbbbbbabaaaa bbabbbbaabaabba babbbbaabbbbbabbbbbbaabaaabaaa aaabbbbbbaaaabaababaabababbabaaabbababababaaa bbbbbbbaaaabbbbaaabbabaaa bbbababbbbaaaaaaaabbababaaababaabab ababaaaaaabaaab ababaaaaabbbaba baabbaaaabbaaaababbaababb abbbbabbbbaaaababbbbbbaaaababb aaaaabbaabaaaaababaa aaaabbaaaabbaaa aaaabbaabbaaaaaaabbbabbbaaabbaabaaa babaaabbbaaabaababbaabababaaab aabbbbbaabbbaaaaaabbbbbababaaaaabbaaabba`; assert.strictEqual(message2(input), 12); }); }); });
23.5875
54
0.500265
93d2adfb0da671255c5704d23e9a90bd09b33378
4,879
js
JavaScript
app/view/laporan/keterlambatan/LaporanKeterlambatanController.js
grouppenggajian/penggajian
fc1a1bb557cce07019f5e8b02e3bf3e157b2cd94
[ "MIT" ]
null
null
null
app/view/laporan/keterlambatan/LaporanKeterlambatanController.js
grouppenggajian/penggajian
fc1a1bb557cce07019f5e8b02e3bf3e157b2cd94
[ "MIT" ]
null
null
null
app/view/laporan/keterlambatan/LaporanKeterlambatanController.js
grouppenggajian/penggajian
fc1a1bb557cce07019f5e8b02e3bf3e157b2cd94
[ "MIT" ]
null
null
null
Ext.define('Penggajian.view.laporan.keterlambatan.LaporanKeterlambatanController', { extend: 'Ext.app.ViewController', alias: 'controller.laporanketerlambatan' , onClickSearch:function(){ if(!Ext.getCmp('lapterlambat_periode').collapsed){ if(Ext.getCmp('lapterlambat_tglawal').getValue()>Ext.getCmp('lapterlambat_tglakhir').getValue()){ set_message(2, 'Tanggal Mulai Lebih Besar Dari Tanggal Selesai!!'); return; } if(Ext.getCmp('lapterlambat_tglawal').getValue()==null || Ext.getCmp('lapterlambat_tglawal').getValue()=='undefined'){ set_message(2, 'Tanggal Mulai Masih Kosong!!'); return; } if(Ext.getCmp('lapterlambat_tglakhir').getValue()==null || Ext.getCmp('lapterlambat_tglakhir').getValue()=='undefined'){ set_message(2, 'Tanggal Selsai Masih Kosong!!'); return; } } var vfield=new Array(); if(Ext.getCmp('lapterlambat_nik_check').getValue()){ vfield.push({field:'nik',value:Ext.getCmp('lapterlambat_nik').getValue()}); } if(Ext.getCmp('lapterlambat_jabatan_check').getValue()){ vfield.push({field:'kode_jabatan',value:Ext.getCmp('lapterlambat_kodejabatan').getValue()}); } if(!Ext.getCmp('lapterlambat_periode').collapsed){ var vtglperiode=new Array(); vtglperiode.push(Ext.getCmp('lapterlambat_tglawal').getValue().toMysql()); vtglperiode.push(Ext.getCmp('lapterlambat_tglakhir').getValue().toMysql()); vfield.push({field:'tgl',value:vtglperiode }); } var vquery=Ext.JSON.encode(vfield); var mymodel=Ext.getCmp('tab3a').getViewModel(); var refstore=mymodel.getData().strlapterlambat; if (vfield.length>0){ refstore.getProxy().setExtraParam('postdata',vquery); refstore.load(); // Ext.getCmp('invsales_h_paging').onLoad(); }else{ refstore.loadRecords([]); // Ext.getCmp('invsales_h_paging').onLoad(); } }, onClickReport:function(){ if(!Ext.getCmp('lapterlambat_periode').collapsed){ if(Ext.getCmp('lapterlambat_tglawal').getValue()>Ext.getCmp('lapterlambat_tglakhir').getValue()){ set_message(2, 'Tanggal Mulai Lebih Besar Dari Tanggal Selesai!!'); return; } if(Ext.getCmp('lapterlambat_tglawal').getValue()==null || Ext.getCmp('lapterlambat_tglawal').getValue()=='undefined'){ set_message(2, 'Tanggal Mulai Masih Kosong!!'); return; } if(Ext.getCmp('lapterlambat_tglakhir').getValue()==null || Ext.getCmp('lapterlambat_tglakhir').getValue()=='undefined'){ set_message(2, 'Tanggal Selsai Masih Kosong!!'); return; } } var vfield=new Array(); if(Ext.getCmp('lapterlambat_nik_check').getValue()){ vfield.push({field:'nik',value:Ext.getCmp('lapterlambat_nik').getValue()}); } if(Ext.getCmp('lapterlambat_jabatan_check').getValue()){ vfield.push({field:'kode_jabatan',value:Ext.getCmp('lapterlambat_kodejabatan').getValue()}); } if(!Ext.getCmp('lapterlambat_periode').collapsed){ var vtglperiode=new Array(); vtglperiode.push(Ext.getCmp('lapterlambat_tglawal').getValue().toMysql()); vtglperiode.push(Ext.getCmp('lapterlambat_tglakhir').getValue().toMysql()); vfield.push({field:'tgl',value:vtglperiode }); } var vquery=Ext.JSON.encode(vfield); var vparamreport=''; if (vfield.length>0){ vparamreport='?postdata='+vquery; }else{ return; } var winpreview=Ext.create({ xtype:'winprint' }); winpreview.maximize(); var query=new Array(); // query.push({name:'transport_by', value:getComp('transrep_transport_by').getValue()}); // query.push({name:'thbl', value:format_date(getComp('transrep_thbl').getValue(), 'Ym')}); // readLog('transport/transportreport_pdf?query='+Ext.JSON.encode(query)); to_print('printoutpdf', 'lapterlambat/loadreport'+vparamreport); } });
46.028302
132
0.534946
93d3058238cbf2273d8109fe2d976d0bb2d05293
792
js
JavaScript
lib/components/ui/panel_vars.js
andreimoldo/ruby-debugger
27910985d047b916e4e2fdfbd79e2bd06acdf9b8
[ "MIT" ]
null
null
null
lib/components/ui/panel_vars.js
andreimoldo/ruby-debugger
27910985d047b916e4e2fdfbd79e2bd06acdf9b8
[ "MIT" ]
null
null
null
lib/components/ui/panel_vars.js
andreimoldo/ruby-debugger
27910985d047b916e4e2fdfbd79e2bd06acdf9b8
[ "MIT" ]
null
null
null
'use babel'; import React from 'react-lite' import Variable from './variable' export default class PanelVars extends React.Component { constructor(props) { super(props); // Events this.props.debugger.client.events.on('variablesChanged', () => this.forceUpdate()); } render() { return ( <atom-panel class="top padded container-vars"> <div className="inset-panel"> <div className="panel-heading">Variables</div> <div className="panel-body"> <ul className="list-group"> {this.props.debugger.variables.map((variable) => { return <Variable variable={variable} debugger={this.props.debugger}/> })} </ul> </div> </div> </atom-panel> ); } }
24.75
87
0.575758
93d34e0f1875ad1934d65e426ea37bc7e58d752c
2,871
js
JavaScript
co-make/src/components/Signup.js
Build-Week-Co-make-5/Front-End
b5efea8a059251cb27c64fc2d7957338114ba554
[ "MIT" ]
null
null
null
co-make/src/components/Signup.js
Build-Week-Co-make-5/Front-End
b5efea8a059251cb27c64fc2d7957338114ba554
[ "MIT" ]
22
2020-03-09T21:58:08.000Z
2022-03-15T20:04:29.000Z
co-make/src/components/Signup.js
Build-Week-Co-make-5/Front-End
b5efea8a059251cb27c64fc2d7957338114ba554
[ "MIT" ]
1
2020-06-18T03:14:18.000Z
2020-06-18T03:14:18.000Z
import React, { useState } from "react"; import { Link } from "react-router-dom"; import { Formik } from "formik"; import styled from "styled-components"; // import UserSignup from './UserSignUp'; import axios from "axios"; const FormWrapper = styled.form` display: flex; flex-direction: column; align-items: center; margin-top: 20px; `; /* Darker teal color: #3EBDC2 Powder blue: #C0EEF0 */ const SignUp = props => ( <div> <br /> <br /> <h1>Sign up form</h1> <Formik initialValues={{ email: "", password: "", full_name: "", }} validate={values => { const errors = {}; if (!values.email) { errors.email = "Required"; } else if ( !/^[A-Z0-9._%+-]+@[A-Z0-9.-]+\.[A-Z]{2,}$/i.test(values.email) ) { errors.email = "Invalid email address"; } return errors; }} onSubmit={(values, { setSubmitting }) => { axios .post( "https://bw-pt-co-make5.herokuapp.com/api/auth/register", values, ) .then(res => { console.log(res); props.history.push("/"); if (res.data) { alert("user account successfully registered"); } else if (res.data) { alert("user account successfully registered"); } }) .catch(error => { console.log(error); }); console.log(values); }}> {({ values, errors, touched, handleChange, handleBlur, handleSubmit, isSubmitting, }) => ( <FormWrapper onSubmit={handleSubmit}> <input type="email" name="email" placeholder="email" onChange={handleChange} onBlur={handleBlur} value={values.email} /> <input type="password" name="password" placeholder="password" onChange={handleChange} onBlur={handleBlur} value={values.password} /> <input type="full_name" name="full_name" placeholder="full_name" onChange={handleChange} onBlur={handleBlur} value={values.full_name} /> {errors.email && touched.email && errors.email} {errors.password && touched.password && errors.password} {errors.full_name && touched.full_name && errors.full_name} {/* <Link to="/"> */} <button type="submit" disabled={isSubmitting}> Submit </button> {/* </Link> */} </FormWrapper> )} </Formik> <br></br> <br></br> {/* <UserSignup /> */} </div> ); export default SignUp;
24.965217
72
0.483455
93d475138497a382bba5ccf27055fc6521571772
3,549
js
JavaScript
test/phonedb-test.js
shanev/phonedb
1b0f843e4bd5c260341be5cdd234182ce7e65fe9
[ "MIT" ]
2
2017-03-15T22:38:44.000Z
2017-03-17T22:42:36.000Z
test/phonedb-test.js
shanev/phonedb
1b0f843e4bd5c260341be5cdd234182ce7e65fe9
[ "MIT" ]
null
null
null
test/phonedb-test.js
shanev/phonedb
1b0f843e4bd5c260341be5cdd234182ce7e65fe9
[ "MIT" ]
null
null
null
const assert = require('assert'); const redis = require('redis'); const { promisify } = require('util'); const client = redis.createClient(); const scard = promisify(client.scard).bind(client); client.on('error', (err) => { console.log(err); }); const PhoneDB = require('../phonedb'); describe('PhoneDB', () => { const phoneDB = new PhoneDB(client); beforeEach(() => { client.flushdb(); }); after(() => { client.flushdb(); // workaround for `nyc mocha` hanging process.exit(0); }); describe('.register()', () => { it('should register a valid phone number', async () => { await phoneDB.register('+18475557777'); const result = await scard('phonedb:registered'); assert.equal(1, result); }); it('should not register an invalid phone number', async () => { try { await phoneDB.register('+1847555777'); } catch (err) { assert(err); } }); it('should not register another invalid phone number', async () => { try { await phoneDB.register('FAKE NEWS! SAD!'); } catch (err) { assert(err); } }); }); describe('.addContacts()', () => { it('should add a list of valid contacts', async () => { const contacts = ['+18475557777', '+14157775555']; const result = await phoneDB.addContacts('user1', contacts); assert.equal(2, result); }); it('should throw error if contact is not a number', async () => { const contacts = ['FAKE NEWS! SAD!', '+14157775555']; try { await phoneDB.addContacts('user1', contacts); } catch (err) { const result = scard('user:user1:contacts'); assert(result); } }); it('should add one valid contact out of a total of 2', async () => { const contacts = ['+1847555777', '+14157775555']; await phoneDB.addContacts('user1', contacts); const result = client.scard('user:user1:contacts'); assert.equal(1, result); }); }); describe('.getMutualContacts()', () => { it('should find mutual contacts between two users', (done) => { phoneDB.addContacts('user1', ['+18475557777', '+14157775555', '+14157775556']); phoneDB.addContacts('user2', ['+18475557777', '+14157775555', '+14157775556']); phoneDB.getMutualContacts('user1', 'user2').then((contacts) => { assert.equal(3, contacts.length); done(); }); }); it('should find mutual registered contacts between two users', (done) => { phoneDB.register('+18475557777'); phoneDB.addContacts('user1', ['+18475557777', '+14157775555', '+14157775556']); phoneDB.addContacts('user2', ['+18475557777', '+14157775555', '+14157775556']); phoneDB.getMutualContacts('user1', 'user2', true).then((contacts) => { assert.equal(1, contacts.length); done(); }); }); }); describe('.getContacts()', () => { it('should find 3 contacts for a user', async () => { await phoneDB.addContacts('user1', ['+18475557777', '+14157775555', '+14157775556']); const result = await phoneDB.getContacts('user1'); assert.equal(3, result.length); }); it('should find 2 registered contacts for a user', (done) => { phoneDB.register('+18475557777'); phoneDB.register('+14157775555'); phoneDB.addContacts('user1', ['+18475557777', '+14157775555', '+14157775556']); phoneDB.getContacts('user1', true).then((users) => { assert.equal(2, users.length); done(); }); }); }); });
30.86087
91
0.584108
93d7aeb42ec031d6f2969193acc6a86b89d64edf
1,025
js
JavaScript
src/visual/boot.js
moaand/miking-ipm
973d7e97a6aa4d17749e9b5b3da80434637a30ec
[ "MIT" ]
null
null
null
src/visual/boot.js
moaand/miking-ipm
973d7e97a6aa4d17749e9b5b3da80434637a30ec
[ "MIT" ]
null
null
null
src/visual/boot.js
moaand/miking-ipm
973d7e97a6aa4d17749e9b5b3da80434637a30ec
[ "MIT" ]
null
null
null
var fs = require('fs'); //Get the file that is being edited var myArgs = process.argv.slice(2); console.log('myArgs: ', myArgs); if(myArgs.length > 1 || myArgs.length == 0){ throw Error ('One file needs to be specified'); } var sourceFile = myArgs[0]; //Create a folder in which the webpage is created and watched var dir = './webpage'; if (!fs.existsSync(dir)){ fs.mkdirSync(dir); } //Temporary: Create a html file to display fs.writeFile('webpage/index.html', '<!DOCTYPE html><html><body><h1>Miking</h1></body></html>', function (err) { if (err) throw err; }); fs.watchFile(sourceFile, { interval: 1000 }, (curr, prev) => { console.log(`${sourceFile} file changed...`); //Re-extract the AST -> JSON from the MCore model to a JSON file and recompile the JS }); //This is being displayed on the browser: use index.html for the moment var bs = require('browser-sync').create(); bs.init({ open: false, watch: true, notify: false, server: "./webpage" }); bs.reload("*.html");
21.808511
111
0.650732
93d8a2b862271b00481f24b382693fc9633ecf79
640
js
JavaScript
files/WEB-INF/attr/js/service/company.js
5112100070/Trek
8017d19af8bf801c4d9691745cda6e12af4dfc1f
[ "MIT" ]
null
null
null
files/WEB-INF/attr/js/service/company.js
5112100070/Trek
8017d19af8bf801c4d9691745cda6e12af4dfc1f
[ "MIT" ]
null
null
null
files/WEB-INF/attr/js/service/company.js
5112100070/Trek
8017d19af8bf801c4d9691745cda6e12af4dfc1f
[ "MIT" ]
1
2018-03-09T11:17:14.000Z
2018-03-09T11:17:14.000Z
function getCompanyDetail(){ var url = product_url + '/company/get-detail'; var promise = $.ajax({ url: url, type: 'GET', xhrFields: { withCredentials: true }, }); return promise; } function RegisterCompany(companyType, companyName){ var url = product_url + '/company/register-company'; var data = { companyType:companyType, companyName:companyName, }; var promise = $.ajax({ url: url, type: 'POST', data: data, xhrFields: { withCredentials: true } }); return promise; }
20
56
0.526563
93d91ce7d1d997c179e2615137e68c45265e63b8
888
js
JavaScript
lib/rules/omit-bool-attributes.js
wxmlfile/eslint-plugin-wxml
f5e4b22317f50eb8fc06740bd3a295e090d097fe
[ "MIT" ]
10
2021-10-24T01:01:32.000Z
2022-02-14T05:50:49.000Z
lib/rules/omit-bool-attributes.js
wxmlfile/eslint-plugin-wxml
f5e4b22317f50eb8fc06740bd3a295e090d097fe
[ "MIT" ]
27
2021-11-02T04:07:38.000Z
2022-03-25T09:36:36.000Z
lib/rules/omit-bool-attributes.js
wxmlfile/eslint-plugin-wxml
f5e4b22317f50eb8fc06740bd3a295e090d097fe
[ "MIT" ]
4
2021-10-22T03:57:00.000Z
2022-03-16T03:23:35.000Z
module.exports = { /** @type {import('eslint').Rule.RuleMetaData} */ meta: { type: "suggestion", docs: { description: "omit true attributes, same with jsx (<A show />)", categories: [], url: "https://eslint-plugin-wxml.js.org/rules/omit-bool-attributes.html", }, fixable: null, messages: { omitWarn: "please omit {{true}}, it means convert <comp {{attrKey}}={{true}} /> to <comp {{attrKey}} />", }, schema: [], }, /** @param {import('eslint').Rule.RuleContext} context */ create(context) { return { WXAttribute(node) { if (node && node.value) { if (node.value.split(" ").join("") === "{{true}}") { context.report({ node, messageId: "omitWarn", data: { attrKey: node.key }, }); } } }, }; }, };
25.371429
103
0.48536
93dbb16d0f1e48c8686cd7ea2e824be859c77a04
1,419
js
JavaScript
src/services/profile/UpdateProfileService.js
duartefdias/CollectorIST-backend
a091a7ce28e2d2609822f3c849bd239bbc2cd512
[ "MIT" ]
null
null
null
src/services/profile/UpdateProfileService.js
duartefdias/CollectorIST-backend
a091a7ce28e2d2609822f3c849bd239bbc2cd512
[ "MIT" ]
null
null
null
src/services/profile/UpdateProfileService.js
duartefdias/CollectorIST-backend
a091a7ce28e2d2609822f3c849bd239bbc2cd512
[ "MIT" ]
null
null
null
import { Mongo, errorWithKey } from 'porg' export default async ({ userId, updatedProfile }) => { const fieldsToSet = {} if (updatedProfile.name) { fieldsToSet.name = updatedProfile.name } if (updatedProfile.username) { fieldsToSet.username = updatedProfile.username } if (updatedProfile.email) { fieldsToSet.email = updatedProfile.email } if (updatedProfile.aliases) { fieldsToSet.aliases = updatedProfile.aliases } if (updatedProfile.completeWizard) { fieldsToSet.wizardState = { completed: true } } if (updatedProfile.website) { fieldsToSet.website = updatedProfile.website } if (updatedProfile.bio) { fieldsToSet.bio = { ...updatedProfile.bio.short && { short: updatedProfile.bio.short }, ...updatedProfile.bio.extended && { extended: updatedProfile.bio.extended } } } if (updatedProfile.fos) { fieldsToSet.fos = { ...updatedProfile.fos.primary && { primary: updatedProfile.fos.primary } } } if (updatedProfile.interests) { fieldsToSet.interests = updatedProfile.interests } if (updatedProfile.locale) { fieldsToSet.locale = updatedProfile.locale } const updateQuery = { $set: fieldsToSet } let db = await Mongo.getDB() let result = await db.collection('users').findOneAndUpdate({ '_id': userId }, updateQuery) if (!result.ok) { throw errorWithKey('user-not-found', { ctx: { userId } }) } }
29.5625
92
0.682171
93dbb4432d274f13ce9ddb1d7122e18fb760db67
472
js
JavaScript
view/index.js
cyea/email-bot
54f929aaee0801be1c97f7e1119017b3f09024ab
[ "MIT" ]
11
2019-03-02T02:10:41.000Z
2019-12-05T02:40:29.000Z
view/index.js
cyea/email-bot
54f929aaee0801be1c97f7e1119017b3f09024ab
[ "MIT" ]
2
2019-07-30T01:39:27.000Z
2019-07-30T01:45:07.000Z
view/index.js
hipi/email-bot
3ff617aec7907688593b7c788daf2828cd3c7281
[ "MIT" ]
1
2019-06-17T08:19:50.000Z
2019-06-17T08:19:50.000Z
const nunjucks = require("nunjucks"); const fs = require("fs"); const path = require("path"); const getHtmlData = njkData => { return new Promise((resolve, reject) => { try { const njkString = fs.readFileSync( path.resolve(__dirname, "index.njk"), "utf8" ); const htmlData = nunjucks.renderString(njkString, njkData); resolve(htmlData); } catch (error) { reject(error); } }); }; module.exports = getHtmlData;
23.6
65
0.610169
93dc59508b7fb9b3d7d1990d9a6c0b57bb825b02
5,905
js
JavaScript
public/vendor/wax/admin/js/general.js
Tootsiebrown/Sitecode
986187228e3e270f803fac934f3e948142219acf
[ "MIT" ]
null
null
null
public/vendor/wax/admin/js/general.js
Tootsiebrown/Sitecode
986187228e3e270f803fac934f3e948142219acf
[ "MIT" ]
null
null
null
public/vendor/wax/admin/js/general.js
Tootsiebrown/Sitecode
986187228e3e270f803fac934f3e948142219acf
[ "MIT" ]
null
null
null
function randomString(length, type) { var chars; switch(type) { case 'password': chars = '123456789abcdefghijkmnopqrstuvwxyzABCDEFGHJKLMNPQRSTUVWXYZ'.split(''); break; case 'mixed_nocase': chars = '0123456789abcdefghiklmnopqrstuvwxyz'.split(''); break; default: chars = '0123456789ABCDEFGHIJKLMNOPQRSTUVWXTZabcdefghiklmnopqrstuvwxyz'.split(''); break; } var str = ''; for (var i = 0; i < length; i++) { str += chars[Math.floor(Math.random() * chars.length)]; } if(type == 'password') { var re = new RegExp("(?=.*\\d)(?=.*[a-z])(?=.*[A-Z]).{" + length + ",}"); if(!re.test(str)) { // this could be made more efficient by looping instead of // recursing, but it should generally only take an iteration or // two anyway. str = randomString(length, type); } } return str; } function urlencode (str) { return encodeURIComponent(str).replace(/!/g, '%21').replace(/'/g, '%27').replace(/\(/g, '%28').replace(/\)/g, '%29').replace(/\*/g, '%2A'); } String.prototype.repeat = function(l){ return new Array(l+1).join(this); } String.prototype.toURL = function() { var str = this.replace(/\s+/g, '-').match(/[a-zA-Z-.\d]/g); return (str == null) ? '' : str.join(''); } function getObject(whichLayer) { if(document.getElementById) elem=document.getElementById(whichLayer); else if (document.all) elem=document.all[whichLayer]; else if (document.layers) elem=document.layers[whichLayer]; return elem; } function getSelectBoxValue(ob) { if(typeof(ob) != "object") ob = getObject(ob); return ob.options[ob.selectedIndex].value; } function setSelectBoxValue(ob, val) { var inpSel = document.getElementById(ob); for(i=0; i<inpSel.options.length; i++) { if(inpSel.options[i].value==val) inpSel.selectedIndex=i; } } function getRadioButtonValue(radioObj) { if(!radioObj) return ""; var radioLength = radioObj.length; if(radioLength == undefined) if(radioObj.checked) return radioObj.value; else return ""; for(var i = 0; i < radioLength; i++) { if(radioObj[i].checked) { return radioObj[i].value; } } return ""; } function numbersonly(str) { var nums = str.match(/[0-9]+/g); if(nums == null) return ""; str = ""; for(i=0; i<nums.length; i++) { str = str + nums[i].toString(); } return str; } String.prototype.numbersonly = function() { return numbersonly(this); } function isvalidemail(str) { var at="@"; var dot="."; var lat=str.indexOf(at); var lstr=str.length; var ldot=str.indexOf(dot); var valid=true; if (str.indexOf(at)==-1) valid = false; if (str.indexOf(at)==-1 || str.indexOf(at)==0 || str.indexOf(at)==lstr) valid = false; if (str.indexOf(dot)==-1 || str.indexOf(dot)==0 || str.indexOf(dot)==lstr) valid = false; if (str.indexOf(at,(lat+1))!=-1) valid = false; if (str.substring(lat-1,lat)==dot || str.substring(lat+1,lat+2)==dot) valid = false; if (str.indexOf(dot,(lat+2))==-1) valid = false; if (str.indexOf(" ")!=-1) valid = false; return valid; } String.prototype.isvalidemail = function() { return isvalidemail(this); } function checkAll(whichfield) { the_field=document.getElementsByName(whichfield); for (i = 0; i < the_field.length; i++) { the_field[i].checked = true ; } } function uncheckAll(whichfield) { the_field=document.getElementsByName(whichfield); for (i = 0; i < the_field.length; i++) { the_field[i].checked = false ; } } function check_url_safe(ob) { var doAlert = true; var val = ob.value; var reg = new RegExp("[^a-zA_Z0-9_./-]", "gi"); if(arguments.length >= 2) doAlert = arguments[1]; if(reg.test(val)) { if(doAlert) alert("Please use only alphanumeric characters or the following special characters:\n _ (underscore)\n - (dash)\n . (period)\n / (forward slash)"); ob.value=ob.value.substring(0, ob.value.length-1); return false; } else { return true; } } function settimeinput(name, hours, minutes) { // Set values using 24-hour time if(arguments.length > 1) { var ampm = "am"; if(hours > 11) { ampm = "pm"; hours = hours - 12; } if(hours == 0) hours = 12; $(name + "_h").val(hours); $(name + "_m").val(minutes); $(name + "_a").val(ampm); } h = $(name + "_h").val(); m = $(name + "_m").val(); a = $(name + "_a").val(); $(name).val(h + ":" + m + " " + a); $(name).trigger('change'); } /** * Function : dump() * Arguments: The data - array,hash(associative array),object * The level - OPTIONAL * Returns : The textual representation of the array. * This function was inspired by the print_r function of PHP. * This will accept some data as the argument and return a * text that will be a more readable version of the * array/hash/object that is given. * Docs: http://www.openjs.com/scripts/others/dump_function_php_print_r.php */ function dump(arr,level) { var dumped_text = ""; if(!level) level = 0; //The padding given at the beginning of the line. var level_padding = ""; for(var j=0;j<level+1;j++) level_padding += " "; if(typeof(arr) == 'object') { //Array/Hashes/Objects for(var item in arr) { var value = arr[item]; if(typeof(value) == 'object' && value != arr) { //If it is an array, dumped_text += level_padding + "'" + item + "' ...\n"; dumped_text += dump(value,level+1); } else { dumped_text += level_padding + "'" + item + "' => \"" + value + "\"\n"; } } } else { //Stings/Chars/Numbers etc. dumped_text = "===>"+arr+"<===("+typeof(arr)+")"; } return dumped_text; } function cloneObject(ob) { var newObj = (ob instanceof Array) ? [] : {}; for (i in ob) { if (i == 'clone') continue; if (ob[i] && typeof ob[i] == "object") { newObj[i] = cloneObject(ob[i]); } else newObj[i] = ob[i] } return newObj; };
25.786026
166
0.611685
93dd609917247862ce345fc086d10959960603f8
3,562
js
JavaScript
common/util/work.js
frj9641/HTE_ERP_NEW_APP
ed6eab940698ba539d96d874df03bea793d05405
[ "Apache-2.0" ]
null
null
null
common/util/work.js
frj9641/HTE_ERP_NEW_APP
ed6eab940698ba539d96d874df03bea793d05405
[ "Apache-2.0" ]
null
null
null
common/util/work.js
frj9641/HTE_ERP_NEW_APP
ed6eab940698ba539d96d874df03bea793d05405
[ "Apache-2.0" ]
null
null
null
/** * 常用服务 * useful server */ const icon_prefix = "/static/home/128/" export const us = { data: [ // { // title:"日报", // icon:icon_prefix+"richang.png", // description:"记录每天的工作经验和心得", // useCount:1000, // page:'helloWorld' // },{ // title:"周报", // icon:icon_prefix+"zhoubao.png", // description:"总结每周的工作情况和下周计划", // useCount:10000, // page:'helloWorld' // },{ // title:"考勤", // icon:icon_prefix+"kaoqin.png", // description:"工作考勤", // useCount:10000, // page:'helloWorld' // },{ // title:"日程", // icon:icon_prefix+"richeng.png", // description:"建立和查看个人工作安排", // useCount:10000, // page:'helloWorld' // },{ // title:"请假申请", // icon:icon_prefix+"qingjia1.png", // description:"请假申请", // useCount:10000, // page:'helloWorld' // },{ // title:"出差申请", // icon:icon_prefix+"chuchai.png", // description:"出差申请", // useCount:10000, // page:'helloWorld' // },{ // title:"公文发文", // icon:icon_prefix+"gongwen.png", // description:"公文发文", // useCount:10000, // page:'helloWorld' // },{ // title:"通知公告", // icon:icon_prefix+"tongzhi.png", // description:"查看企业对员工下发的通知公告", // useCount:10000, // page:'annotationList' // },{ // title:"内部邮件", // icon:icon_prefix+"youjian.png", // description:"查看内部消息", // useCount:10000, // dot:false, // page:'helloWorld' // },{ // title:"通讯录", // icon:icon_prefix+"tongxun.png", // description:"查看部门,组员", // useCount:10000, // page:'levelAddressBook' // }, { title: "采购业务", icon: icon_prefix + "hetong.png", description: "采购业务", useCount: 10000, page: 'purchase' }, { title: "入库业务", icon: icon_prefix + "hetong.png", description: "入库业务", useCount: 10000, page: 'rk' }, { title: "出库业务", icon: icon_prefix + "hetong.png", description: "出库业务", useCount: 10000, page: 'ck' }, { title: "产出品业务", icon: icon_prefix + "hetong.png", description: "产出品业务", useCount: 10000, page: 'product' }, { title: "入库质量数据采集", icon: icon_prefix + "renwu.png", description: "入库质量数据采集", useCount: 10000, page: 'rkData' }, { title: "产出品质量数据采集", icon: icon_prefix + "renwu.png", description: "产出品质量数据采集", useCount: 10000, page: 'productData' }, { title: "质量数据采集", icon: icon_prefix + "renwu.png", description: "质量数据采集", useCount: 10000, page: 'dataCollect' } ] } /** * other server 其他服务 */ export const os = { data: [ // { // title:"新闻中心", // icon:icon_prefix+"xinwen.png", // description:"新闻中心", // useCount:10000, // page:'helloWorld' // },{ // title:"投票中心", // icon:icon_prefix+"toupiao.png", // description:"投票中心", // useCount:10000, // page:'helloWorld' // },{ // title:"任务中心", // icon:icon_prefix+"renwu.png", // description:"任务中心", // useCount:10000, // page:'helloWorld' // },{ // title:"文档中心", // icon:icon_prefix+"wendang.png", // description:"文档中心", // useCount:10000, // page:'helloWorld' // },{ // title:"合同", // icon:icon_prefix+"hetong.png", // description:"合同", // useCount:10000, // page:'helloWorld' // },{ // title:"会议", // icon:icon_prefix+"huiyi.png", // description:"会议", // useCount:10000, // page:'helloWorld' // },{ // title:"客户关系", // icon:icon_prefix+"tongzhi.png", // description:"客户关系", // useCount:10000, // page:'helloWorld' // } ] }
21.202381
40
0.545199
93dd78101ff70c3c5e8b653de594514fe2715b7b
606
js
JavaScript
src/constant/metamonCategories.js
nguyentrn/metamon-client
842a0393ebffe372d95c7a146adad3afb3770751
[ "ISC" ]
3
2022-03-20T13:49:36.000Z
2022-03-23T12:24:24.000Z
src/constant/metamonCategories.js
nguyentrn/metamon-client
842a0393ebffe372d95c7a146adad3afb3770751
[ "ISC" ]
1
2022-02-20T16:20:37.000Z
2022-02-20T16:20:37.000Z
src/constant/metamonCategories.js
nguyentrn/metamon-client
842a0393ebffe372d95c7a146adad3afb3770751
[ "ISC" ]
1
2022-02-20T15:29:11.000Z
2022-02-20T15:29:11.000Z
const metamonCategories = [ { code: "MetamonA", name: "Metamon Avatar", id: 5, tokenId: -1, slug: "metamon_a", }, { code: "Metamon", name: "Metamon", id: 13, tokenId: -1, slug: "metamon_n", }, { code: "RMetamon", name: "R-Metamon", id: 23, tokenId: -1, slug: "metamon_r", }, { code: "SRMetamon", name: "SR-Metamon", id: 24, tokenId: -1, slug: "metamon_sr", }, { code: "SSRMetamon", name: "SSR-Metamon", id: 25, tokenId: -1, slug: "metamon_ssr", }, ]; export default metamonCategories;
15.15
33
0.508251
93dfcb2023218c8436e125c1cecea4852b7a31f6
161
js
JavaScript
app/src/BusinessLogic/index.js
drazenbuljovcic/tree-shaking-project
843e15661c7c32f611fbe57baeb198acdaef18c2
[ "MIT" ]
null
null
null
app/src/BusinessLogic/index.js
drazenbuljovcic/tree-shaking-project
843e15661c7c32f611fbe57baeb198acdaef18c2
[ "MIT" ]
1
2021-05-10T21:04:00.000Z
2021-05-10T21:04:00.000Z
app/src/BusinessLogic/index.js
zendra1994/tree-shaking-project
843e15661c7c32f611fbe57baeb198acdaef18c2
[ "MIT" ]
null
null
null
const BusinessLogic = () => { const init = () => { console.log('Initializing Business Logic!'); }; return { init }; }; export default BusinessLogic;
16.1
48
0.608696
93e00231124916bcafa62de9fdf8b69bbbbf2dce
138
js
JavaScript
src/managed-entities.js
softilabs/angular-dictate
77bda5cba0fd9e888f96cc1e5f271ecf8addcd94
[ "MIT" ]
3
2015-07-15T09:55:19.000Z
2016-05-31T22:07:07.000Z
src/managed-entities.js
softilabs/angular-dictate
77bda5cba0fd9e888f96cc1e5f271ecf8addcd94
[ "MIT" ]
null
null
null
src/managed-entities.js
softilabs/angular-dictate
77bda5cba0fd9e888f96cc1e5f271ecf8addcd94
[ "MIT" ]
null
null
null
angular .module('softilabs.ngDictate.managedEntities', []) .factory('$dictateEntities', function () { return {}; });
19.714286
54
0.594203
93e104b8b974480d036516b9ee15d514d881433d
1,256
js
JavaScript
packages/core/src/iterator/__tests__/traverse.spec.js
machinat/machinat
ea9bba239ef68f2a94c0ecdab7228863279f5419
[ "MIT" ]
18
2021-07-31T20:14:26.000Z
2022-02-24T12:30:32.000Z
packages/core/src/iterator/__tests__/traverse.spec.js
machinat/machinat
ea9bba239ef68f2a94c0ecdab7228863279f5419
[ "MIT" ]
13
2021-06-17T15:09:43.000Z
2022-02-17T12:22:02.000Z
packages/core/src/iterator/__tests__/traverse.spec.js
machinat/machinat
ea9bba239ef68f2a94c0ecdab7228863279f5419
[ "MIT" ]
4
2021-07-17T18:10:30.000Z
2022-02-24T08:01:52.000Z
import Machinat from '../..'; import traverse from '../traverse'; it('traverse through node tree and pass all non empty element to callback', () => { const context = {}; const callback = jest.fn(); expect( traverse( <> {null} first {[<a>second</a>, [<third />]]} <i>fourth</i> <> fifth <> <b>sixth</b> </> </> <seventh /> {undefined} {{ n: 'eight' }} {true} {false} </>, '$', context, callback ) ).toBe(8); expect(callback.mock.calls).toEqual([ ['first', '$::1', context], [<a>second</a>, '$::2:0', context], [<third />, '$::2:1:0', context], [<i>fourth</i>, '$::3', context], ['fifth', '$::4::0', context], [<b>sixth</b>, '$::4::1::0', context], [<seventh />, '$::5', context], [{ n: 'eight' }, '$::7', context], ]); }); test('if a Fragment contains only one child, path be shown as first children', () => { const context = {}; const callback = jest.fn(); expect(traverse(<>hello</>, '$', context, callback)).toBe(1); expect(callback).toHaveBeenCalledTimes(1); expect(callback).toHaveBeenCalledWith('hello', '$::0', context); });
24.627451
86
0.48328
93e13c112e10264e279a39cd6f58a78cfec512fc
751
js
JavaScript
routes/users/middleware.js
lulebe/turn-based-gameserver
59098292ee3b5db2f486d197ab6e02ee51184c87
[ "MIT" ]
null
null
null
routes/users/middleware.js
lulebe/turn-based-gameserver
59098292ee3b5db2f486d197ab6e02ee51184c87
[ "MIT" ]
null
null
null
routes/users/middleware.js
lulebe/turn-based-gameserver
59098292ee3b5db2f486d197ab6e02ee51184c87
[ "MIT" ]
null
null
null
const jwt = require('jsonwebtoken') const User = require('../../db').User const AppError = require('../../error') const config = require('../../config') module.exports = { auth (req, res, next) { console.log(req.headers) if (!req.headers.authorization) res.status(401).send() jwt.verify(req.headers.authorization, config.jwtKey, (err, tokenPayload) => { if (err) return res.status(401).send() User.findById(tokenPayload.userId) .then(user => { if (!user) return Promise.reject(new AppError(401, 'User not found')) req.user = user next() }) .catch(e => { res.status(e.httpStatus || 500).send(e.message) }) }) } }
27.814815
82
0.55526
93e187da027c6a87acc32b2cbdd2ec4bc6698ca9
114
js
JavaScript
app/index.js
apoutchika/girouette
8d0b3c4acb16dd59c80f029cd8415fbee8280183
[ "MIT" ]
null
null
null
app/index.js
apoutchika/girouette
8d0b3c4acb16dd59c80f029cd8415fbee8280183
[ "MIT" ]
2
2021-03-10T11:11:14.000Z
2022-01-16T16:33:48.000Z
app/index.js
apoutchika/girouette
8d0b3c4acb16dd59c80f029cd8415fbee8280183
[ "MIT" ]
null
null
null
'use strict' require('./libs/initRootCA') require('./libs/initDockerEvents') require('./app') require('./proxy')
16.285714
34
0.692982
93e2dd508e7d70bcdf200fc50f1126a6f979d079
2,074
js
JavaScript
browser/menu.js
dchandran/cubid
e548deebc0d439672b1b9f32fe690bc4eca73954
[ "MIT" ]
null
null
null
browser/menu.js
dchandran/cubid
e548deebc0d439672b1b9f32fe690bc4eca73954
[ "MIT" ]
null
null
null
browser/menu.js
dchandran/cubid
e548deebc0d439672b1b9f32fe690bc4eca73954
[ "MIT" ]
null
null
null
const BurgerMenu = require('react-burger-menu').slide; const Dropzone = require('react-dropzone'); require('./images/open_file.png'); require('./images/map.png'); require('./images/movie.png'); require('./images/python.png'); require('./styles/menu.css'); class Menu extends React.Component { render() { let menuStyles = { bmBurgerButton: { position: 'fixed', width: '2em', height: '2em', left: '1em', top: '1em' }, bmBurgerBars: { background: '#373a47' }, bmCrossButton: { height: '1em', width: '1em' }, bmCross: { background: '#bdc3c7' }, bmMenu: { background: '#373a47', padding: '0 0 0', fontSize: '1.30em' }, bmMorphShape: { fill: '#373a47' }, bmItemList: { color: '#b8b7ad', padding: '1.8em' }, bmOverlay: { background: 'rgba(0, 0, 0, 0.2)' } } let menuItems = [ { class: 'mapButton', tooltip: 'Overall concept design' }, { class: 'animationButton', tooltip: 'Animate the simulated results' }, { class: 'pythonButton', tooltip: 'Python code for simulating the system' } ]; let myFunc = () => { debugger; }; let onDrop = (files) => { debugger; }; let dropZoneStyles = { width: "2em", height: "2em" }; return (<BurgerMenu styles={menuStyles} width={150}> <div className="tooltip" data-hint="Open a project file"> <Dropzone className="menuButton fileOpenButton" onDrop={onDrop}/> </div> { menuItems.map(function(item) { let classNames = "menuButton tooltip " + item.class; return ( <div className="tooltip" data-hint={item.tooltip}> <input type="button" onClick={myFunc} className={classNames}/> </div>); }) } </BurgerMenu>); } } export default Menu;
22.301075
76
0.508197
93e3c497b583cd88546816440f9547d085299393
262
js
JavaScript
src/cache.js
wolfram77/extra-npm.folders
c129dce453c171d9ef37a896b413f9b4a06d9d9c
[ "MIT" ]
null
null
null
src/cache.js
wolfram77/extra-npm.folders
c129dce453c171d9ef37a896b413f9b4a06d9d9c
[ "MIT" ]
1
2020-12-16T14:15:35.000Z
2020-12-16T14:15:35.000Z
src/cache.js
wolfram77/extra-npm.folders
c129dce453c171d9ef37a896b413f9b4a06d9d9c
[ "MIT" ]
null
null
null
'use strict'; const path = require('path'); const os = require('os'); const E = process.env; function cache() { if (process.platform !== 'win32') return path.join(os.homedir(), '.npm'); return path.join(E.APPDATA, 'npm-cache'); } module.exports = cache;
18.714286
75
0.648855
93e5537ec05d8943552c476151160fd61b8d1677
2,536
js
JavaScript
dist/DocsDropdownButton.js
chanzuckerberg/education-doc-editor
8a9a9549010d7c1ad3a910c5b5ab9b7eaf09c968
[ "MIT" ]
7
2018-11-14T17:15:17.000Z
2021-05-26T16:17:52.000Z
dist/DocsDropdownButton.js
chanzuckerberg/education-doc-editor
8a9a9549010d7c1ad3a910c5b5ab9b7eaf09c968
[ "MIT" ]
5
2020-06-15T21:35:54.000Z
2021-09-01T05:03:10.000Z
dist/DocsDropdownButton.js
chanzuckerberg/education-doc-editor
8a9a9549010d7c1ad3a910c5b5ab9b7eaf09c968
[ "MIT" ]
3
2019-06-21T19:36:44.000Z
2021-07-13T19:25:28.000Z
'use strict'; var _extends2 = require('babel-runtime/helpers/extends'); var _extends3 = _interopRequireDefault(_extends2); var _getPrototypeOf = require('babel-runtime/core-js/object/get-prototype-of'); var _getPrototypeOf2 = _interopRequireDefault(_getPrototypeOf); var _classCallCheck2 = require('babel-runtime/helpers/classCallCheck'); var _classCallCheck3 = _interopRequireDefault(_classCallCheck2); var _createClass2 = require('babel-runtime/helpers/createClass'); var _createClass3 = _interopRequireDefault(_createClass2); var _possibleConstructorReturn2 = require('babel-runtime/helpers/possibleConstructorReturn'); var _possibleConstructorReturn3 = _interopRequireDefault(_possibleConstructorReturn2); var _inherits2 = require('babel-runtime/helpers/inherits'); var _inherits3 = _interopRequireDefault(_inherits2); var _react = require('react'); var _react2 = _interopRequireDefault(_react); var _classnames = require('classnames'); var _classnames2 = _interopRequireDefault(_classnames); var _reactBootstrap = require('react-bootstrap'); var _uniqueID = require('./uniqueID'); var _uniqueID2 = _interopRequireDefault(_uniqueID); function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } var DocsDropdownButton = function (_React$PureComponent) { (0, _inherits3.default)(DocsDropdownButton, _React$PureComponent); function DocsDropdownButton() { var _ref; var _temp, _this, _ret; (0, _classCallCheck3.default)(this, DocsDropdownButton); for (var _len = arguments.length, args = Array(_len), _key = 0; _key < _len; _key++) { args[_key] = arguments[_key]; } return _ret = (_temp = (_this = (0, _possibleConstructorReturn3.default)(this, (_ref = DocsDropdownButton.__proto__ || (0, _getPrototypeOf2.default)(DocsDropdownButton)).call.apply(_ref, [this].concat(args))), _this), _this._mouseDownTarget = null, _this._id = (0, _uniqueID2.default)(), _temp), (0, _possibleConstructorReturn3.default)(_this, _ret); } (0, _createClass3.default)(DocsDropdownButton, [{ key: 'render', value: function render() { var className = (0, _classnames2.default)(this.props.className, 'docs-dropdown-button'); return _react2.default.createElement(_reactBootstrap.DropdownButton, (0, _extends3.default)({ className: className, 'data-docs-tool': 'true', id: this._id }, this.props)); } }]); return DocsDropdownButton; }(_react2.default.PureComponent); module.exports = DocsDropdownButton;
34.27027
354
0.745662
93e68bca97e1b51c028e6e5cee32c02d55dc1d30
610
js
JavaScript
frontend/node_modules/.pnpm/@rsuite+icons@1.0.2_react-dom@17.0.2+react@17.0.2/node_modules/@rsuite/icons/lib/icons/legacy/ThLarge.js
koenw/fullstack-hello
6a2317b7e6ace4b97134e7cc2bb5b1159b556d78
[ "Apache-2.0", "MIT" ]
2
2021-11-26T00:46:16.000Z
2021-11-27T06:55:57.000Z
frontend/node_modules/.pnpm/@rsuite+icons@1.0.2_react-dom@17.0.2+react@17.0.2/node_modules/@rsuite/icons/lib/icons/legacy/ThLarge.js
koenw/fullstack-hello
6a2317b7e6ace4b97134e7cc2bb5b1159b556d78
[ "Apache-2.0", "MIT" ]
2
2022-01-18T13:54:05.000Z
2022-03-24T01:18:30.000Z
frontend/node_modules/.pnpm/@rsuite+icons@1.0.2_react-dom@17.0.2+react@17.0.2/node_modules/@rsuite/icons/lib/icons/legacy/ThLarge.js
koenw/fullstack-hello
6a2317b7e6ace4b97134e7cc2bb5b1159b556d78
[ "Apache-2.0", "MIT" ]
null
null
null
"use strict"; var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault"); exports.__esModule = true; exports["default"] = void 0; var _createSvgIcon = _interopRequireDefault(require("../../createSvgIcon")); var _ThLarge = _interopRequireDefault(require("@rsuite/icon-font/lib/legacy/ThLarge")); // Generated by script, don't edit it please. var ThLarge = (0, _createSvgIcon["default"])({ as: _ThLarge["default"], ariaLabel: 'th large', category: 'legacy', displayName: 'ThLarge' }); var _default = ThLarge; exports["default"] = _default; module.exports = exports.default;
29.047619
87
0.732787
93e74f7f9fca42755549e57e125f5e114e94ffbf
4,419
js
JavaScript
packages/handlebars-serializer/lib/serializer.js
zeppelin/handlebars-serializer
db7ef981e171116a5f2c293fe980ad235c3ea829
[ "MIT" ]
4
2015-02-03T11:05:59.000Z
2020-01-08T21:37:53.000Z
packages/handlebars-serializer/lib/serializer.js
zeppelin/handlebars-serializer
db7ef981e171116a5f2c293fe980ad235c3ea829
[ "MIT" ]
1
2018-01-03T19:48:04.000Z
2020-06-04T09:16:48.000Z
packages/handlebars-serializer/lib/serializer.js
zeppelin/handlebars-serializer
db7ef981e171116a5f2c293fe980ad235c3ea829
[ "MIT" ]
2
2015-06-22T06:12:00.000Z
2019-10-25T14:56:24.000Z
import Visitor from './visitor'; export default class Serializer extends Visitor { /** Serializes a `Handlebars.AST.ProgramNode` @method program @param {Handlebars.AST.ProgramNode} program @return {String} The serialized string */ program(programNode) { var out = ''; var self = this; (programNode.statements || []).forEach(function(statement) { out += self.accept(statement); }); return out; } /** Serializes a `Handlebars.AST.BlockNode` @method block @param {Handlebars.AST.BlockNode} block @return {String} The serialized string */ block(blockNode) { var out = this.accept(blockNode.mustache, { openingTag: true }); if (blockNode.program) { out += this.accept(blockNode.program); } if (blockNode.inverse) { var inverse = this.accept(blockNode.inverse); out += `{{^}}${inverse}`; } return `${out}{{/${this.accept(blockNode.mustache.id)}}}`; } /** Serializes a `Handlebars.AST.MustacheNode`. Pass `{openingTag: true}` option to get an opening tag for a block @method mustache @param {Handlebars.AST.MustacheNode} mustache @param {Object} options @return {String} The serialized string */ mustache(mustacheNode, options) { var paramStrings = ''; var self = this; (mustacheNode.params || []).forEach(function(param) { paramStrings += ` ${self.accept(param)}`; }); var hash = mustacheNode.hash ? this.accept(mustacheNode.hash) : ''; var hashmarkOrEmptyString = options.openingTag ? '#' : ''; var out = `{{${hashmarkOrEmptyString}`; out += this.accept(mustacheNode.id) + paramStrings + hash; out += '}}'; if (mustacheNode.escaped) { return out; } return `{${out}}`; } /** Serializes a `Handlebars.AST.PartialNode` @method partial @param {Handlebars.AST.PartialNode} partial @return {String} The serialized string */ partial(partialNode) { var content = this.accept(partialNode.partialName); if (partialNode.context) { var context = partialNode.context; var acceptedContext = this.accept(context); content += ` ${acceptedContext}`; } return `{{>${content}}}`; } /** Serializes a `Handlebars.AST.HashNode` @method hash @param {Handlebars.AST.HashNode} hash @return {String} The serialized string */ hash(hashNode) { var out = ''; var self = this; (hashNode.pairs || []).forEach(function(pair) { out += ' ' + pair[0] + '=' + self.accept(pair[1]); }); return out; } /** Serializes a `Handlebars.AST.StringNode` @method STRING @param {Handlebars.AST.StringNode} string @return {String} The serialized string */ STRING(string) { return `"${string.string}"`; } /** Serializes a `Handlebars.AST.IntegerNode` @method INTEGER @param {Handlebars.AST.IntegerNode} integer @return {String} The serialized string */ INTEGER(integer) { return integer.integer; } /** Serializes a `Handlebars.AST.BooleanNode` @method BOOLEAN @param {Handlebars.AST.BooleanNode} bool @return {String} The serialized string */ BOOLEAN(boolean) { return boolean.bool; } /** Serializes a `Handlebars.AST.PartialNameNode` @method PARTIAL_NAME @param {Handlebars.AST.PartialNameNode} partialName @return {String} The serialized string */ PARTIAL_NAME(partialName) { return partialName.name; } /** Serializes a `Handlebars.AST.IdNode` @method ID @param {Handlebars.AST.IdNode} id @return {String} The serialized string */ ID(id) { return id.string; } /** Serializes a `Handlebars.AST.DataNode` @method DATA @param {Handlebars.AST.BlockNode} data @return {String} The serialized string */ DATA(data) { var id = this.accept(data.id); return `@${id}`; } /** Serializes a `Handlebars.AST.ContentNode` @method content @param {Handlebars.AST.ContentNode} content @return {String} The serialized string */ content(contentNode) { return contentNode.string; } /** Serializes a `Handlebars.AST.CommentNode` @method comment @param {Handlebars.AST.BlockNode} comment @return {String} The serialized string */ comment(commentNode) { return `{{!--${commentNode.comment}--}}`; } }
21.556098
71
0.628875
93e7d1362fce59022a57415cd78e617c91a689d4
902
js
JavaScript
src/api/selection/selectionLink.js
fguo520/office
1b08626796faa15ea136b2f28b7f8934dbe16251
[ "Apache-2.0" ]
null
null
null
src/api/selection/selectionLink.js
fguo520/office
1b08626796faa15ea136b2f28b7f8934dbe16251
[ "Apache-2.0" ]
null
null
null
src/api/selection/selectionLink.js
fguo520/office
1b08626796faa15ea136b2f28b7f8934dbe16251
[ "Apache-2.0" ]
null
null
null
import createAxios from '@/utils/axios' const request = createAxios(process.env.SELECT_API) // 查询店铺链接管理列表 export function list(data) { return request({ url: '/selection/storeLink/list', method: 'post', data }) } // 获取下拉信息(平台信息) export function getPlatforms() { return request({ url: '/selection/storeLink/getPlatforms', method: 'get', }) } export function getAddUsers() { return request({ url: '/selection/storeLink/getAddUsers', method: 'get', }) } // 添加店铺链接 export function add(data) { return request({ url: '/selection/storeLink/add', method: 'post', data }) } // 批量删除 export function batchDelete(data) { return request({ url: '/selection/storeLink/delete', method: 'post', data }) } //日志 export function getLogList(data) { return request({ url: '/selection/storeLink/getLogList', method: 'post', data }) }
17.346154
51
0.644124
93e89a44532ca8bf63d1d76b9b60dbf2137edf4e
759
js
JavaScript
src/config/swaggerConfig.js
habibis007/swagger-jwt-authentication
31d1b9d2ae7d160093cdac3b360e88e7677a58c9
[ "MIT" ]
null
null
null
src/config/swaggerConfig.js
habibis007/swagger-jwt-authentication
31d1b9d2ae7d160093cdac3b360e88e7677a58c9
[ "MIT" ]
null
null
null
src/config/swaggerConfig.js
habibis007/swagger-jwt-authentication
31d1b9d2ae7d160093cdac3b360e88e7677a58c9
[ "MIT" ]
null
null
null
const{SERVER_URL, BASE_PATH, API_PORT, HTTP_PROTOCOL} = require('./serverConfig'); const host = `${HTTP_PROTOCOL}${SERVER_URL}:${API_PORT}` || 'localhost:3001'; const swaggerDefinition = { openapi: '3.0.0', info: { title: 'Sample API', description: '', version: '1.0.0', contact: { email: 'hksalaudeen@gmail.com' } }, components: { securitySchemes: { bearerAuth: { type: 'http', scheme: 'bearer', bearerFormat: 'JWT', } } }, security: [{ bearerAuth: [] }] }; module.exports = { swaggerDefinition, host, basePath: BASE_PATH, apis: [ 'src/routes/*.js' ] }
21.685714
82
0.491436
93e925a55dace3c1ab105647e6a4ec5aab3f7fdb
126
js
JavaScript
db.js
furyanPDX/upgraded-octo-guacamole
8b941ec6c7ed2f64d64f47e33df45cd287a85ad7
[ "MIT" ]
null
null
null
db.js
furyanPDX/upgraded-octo-guacamole
8b941ec6c7ed2f64d64f47e33df45cd287a85ad7
[ "MIT" ]
null
null
null
db.js
furyanPDX/upgraded-octo-guacamole
8b941ec6c7ed2f64d64f47e33df45cd287a85ad7
[ "MIT" ]
null
null
null
const mongoose = require('mongoose'); const settings = require('./config/settings'); mongoose.connect(settings.mongodbUri)
31.5
47
0.753968
93ea51447247eb22dea43e94909ef6a2ebc3cf24
829
js
JavaScript
pages/waitingArea.js
cksharma11/Ludo-UI
6beb9b16243badfd260e76b4fd5bdb3ba4e5c209
[ "MIT" ]
null
null
null
pages/waitingArea.js
cksharma11/Ludo-UI
6beb9b16243badfd260e76b4fd5bdb3ba4e5c209
[ "MIT" ]
1
2020-04-24T06:09:51.000Z
2020-04-24T06:10:14.000Z
pages/waitingArea.js
cksharma11/Ludo-UI
6beb9b16243badfd260e76b4fd5bdb3ba4e5c209
[ "MIT" ]
null
null
null
/* eslint-disable no-unused-vars */ import React from 'react'; // eslint-disable-next-line import/no-extraneous-dependencies import regeneratorRuntime from 'regenerator-runtime'; import WaitingArea from '../components/WaitingArea/WaitingArea'; import { isWindow, parseCookie } from '../utils/utils'; import GlobalStyles from '../components/globalStyles'; import PageLayout from '../components/PageLayout/PageLayout'; const WaitingAreaPage = () => { if (isWindow()) { const { gameId } = parseCookie(document.cookie); return ( <PageLayout> <WaitingArea gameId={gameId} /> <style jsx>{GlobalStyles}</style> </PageLayout> ); } return ( <PageLayout> <WaitingArea gameId={1} /> <style jsx>{GlobalStyles}</style> </PageLayout> ); }; export default WaitingAreaPage;
27.633333
64
0.681544
93eae47c5707e1914206793324dbaf39ae8e4d8a
5,880
js
JavaScript
src/gamut.js
CIELab-gamut-tools/gamut-js
61d2c3a11e6e21d62161a44d49300007ba87500a
[ "MIT" ]
3
2021-12-24T05:24:57.000Z
2022-02-16T20:31:32.000Z
src/gamut.js
CIELab-gamut-tools/gamut-js
61d2c3a11e6e21d62161a44d49300007ba87500a
[ "MIT" ]
null
null
null
src/gamut.js
CIELab-gamut-tools/gamut-js
61d2c3a11e6e21d62161a44d49300007ba87500a
[ "MIT" ]
null
null
null
import {readCgats} from "./cgats"; import {from, min, max, cross, product, mapMany, sum} from 't-matrix'; import {camcat_cc, makeTesselation, mapRows, XYZ2Lab, find} from "./util"; export function fromCgats(file, opts) { const g = readCgats(file); const RGBp = ['RGB_R', 'RGB_G', 'RGB_B'], XYZp = ['XYZ_X', 'XYZ_Y', 'XYZ_Z']; for (let prop of [...RGBp, ...XYZp]) { if (!g.format.hasOwnProperty(prop)) { throw new Error('GAMUT:: Cgats file must have the following data - ' + PROPS.join(', ')); } } g.RGB = g.data.get(':', RGBp.map(p => g.format[p])); g.XYZ = g.data.get(':', XYZp.map(p => g.format[p])); Object.assign(g, opts); return fromXYZ(g); } export function fromXYZ(g) { g.gsv = [...new Set(g.RGB)].sort((a, b) => a - b); const [TRI_ref, RGB_ref] = makeTesselation(g.gsv); const map = mapRows(RGB_ref, g.RGB, g.gsv); if (map.indexOf(undefined) >= 0) throw new Error('GAMUT:: Missing RGB data'); g.TRI = TRI_ref.map(i => map[i]); return fromTRIXYZ(g); } export function fromTRIXYZ(g) { g.RGBmax = g.gsv[g.gsv.length - 1]; g.XYZn = g.XYZ.get([...min(g.RGB, null, 2)].indexOf(g.RGBmax), ':'); // D50 is the default chromatic adaptation if (!g.caXYZn) g.caXYZn = from([[0.9642957, 1, 0.8251046]]) g.caXYZ = camcat_cc(g.XYZ, g.XYZn, g.caXYZn); g.LAB = XYZ2Lab(g.caXYZ, g.caXYZn); return fromTRILAB(g) } export function _fromTRILAB(g) { if (!g.Lsteps) g.Lsteps = 100; if (!g.hsteps) g.hsteps = 360; const {TRI, LAB, Lsteps, hsteps} = g; const Z = LAB.get(':', [1, 2, 0]); const maxL = max( Z.get([...TRI.get(':', 0)], 2), Z.get([...TRI.get(':', 1)], 2), Z.get([...TRI.get(':', 2)], 2)); const minL = min( Z.get([...TRI.get(':', 0)], 2), Z.get([...TRI.get(':', 1)], 2), Z.get([...TRI.get(':', 2)], 2)); const deltaHue = 2 * Math.PI / hsteps; //quick way of building a 2D array. const cylmap = new Array(Lsteps); for (let p = 0; p < Lsteps; p++) { let Lmid = (p + 0.5) * 100 / Lsteps, orig = from([[0, 0, Lmid]]), IX = find(mapMany(minL, maxL, (mn, mx) => mn <= Lmid && Lmid < mx)), vert0 = Z.get([...TRI.get(IX, 0)], ':'), vert1 = Z.get([...TRI.get(IX, 1)], ':'), vert2 = Z.get([...TRI.get(IX, 2)], ':'), edge1 = mapMany(vert1, vert0, (v1, v0) => v1 - v0), edge2 = mapMany(vert2, vert0, (v2, v0) => v2 - v0), o = mapMany(orig, vert0, (or, v0) => or - v0), e2e1 = cross(edge2, edge1, 2), e2o = cross(edge2, o, 2), oe1 = cross(o, edge1, 2); //from here, drop down to plain arrays for speed in the inner loop. cylmap[p]=inner( [...e2e1.get(':', [0, 1])], [...e2o.get(':', [0, 1])], [...oe1.get(':', [0, 1])], [...sum(product(edge2, oe1), null, 2)], hsteps, deltaHue ); } g.cylmap = cylmap; return g; } export function fromTRILAB(g) { if (!g.Lsteps) g.Lsteps = 100; if (!g.hsteps) g.hsteps = 360; const {TRI, LAB, Lsteps, hsteps} = g; const tri = new Uint32Array(TRI); const lab = new Float64Array(LAB); const L = tri.length/3; const maxL = new Float64Array(L), minL = new Float64Array(L); for (let i=0,j=0;j<L; j++){ const l1 = lab[tri[i++]*3], l2 = lab[tri[i++]*3], l3 = lab[tri[i++]*3]; if (l1>l2){ if (l2>l3){ minL[j]=l3; maxL[j]=l1; } else { minL[j]=l2; maxL[j]=l1>l3?l1:l3; } } else { if (l2>l3){ minL[j]=l1>l3?l3:l1; maxL[j]=l2; } else { minL[j]=l1; maxL[j]=l3; } } maxL[j] = Math.max(l1, l2, l3); minL[j] = Math.min(l1, l2, l3); } const deltaHue = 2 * Math.PI / hsteps; //quick way of building a 2D array. const cylmap = new Array(Lsteps); for (let p = 0; p < Lsteps; p++) { const Lmid = (p + 0.5) * 100 / Lsteps; const IX = []; for (let j=0;j<L;j++) if (minL[j] <= Lmid && Lmid < maxL[j]) IX.push(j); const N = IX.length, e2e1 = new Float64Array(N*2), e2o = new Float64Array(N*2), oe1 = new Float64Array(N*2), e2oe1 = new Float64Array(N); for (let k=0, i=0;k<N;k++, i+=2){ const j=IX[k]*3, t0=tri[j]*3, t1=tri[j+1]*3, t2=tri[j+2]*3; const v0l=lab[t0], v0a=lab[t0+1], v0b=lab[t0+2]; const v1l=lab[t1], v1a=lab[t1+1], v1b=lab[t1+2]; const v2l=lab[t2], v2a=lab[t2+1], v2b=lab[t2+2]; const e1l=v1l-v0l, e1a=v1a-v0a, e1b=v1b-v0b; const e2l=v2l-v0l, e2a=v2a-v0a, e2b=v2b-v0b; const ol = Lmid-v0l, oa=-v0a, ob=-v0b; e2e1[i]=e2b*e1l-e2l*e1b; e2e1[i+1]=e1a*e2l-e2a*e1l; e2o[i]=e2b*ol-e2l*ob; e2o[i+1]=oa*e2l-e2a*ol; oe1[i]=ob*e1l-ol*e1b; oe1[i+1]=e1a*ol-oa*e1l; e2oe1[k]=e2a*oe1[i]+e2b*oe1[i+1]+e2l*(oa*e1b-e1a*ob); } cylmap[p]=inner( e2e1, e2o, oe1, e2oe1, hsteps, deltaHue ); } g.cylmap = cylmap; return g; } function inner(e2e1, e2o, oe1, e2oe1, hsteps, deltaHue) { const L = e2oe1.length; const rtn = new Array(hsteps); for (let q = 0; q < hsteps; q++) { const dat = []; const Hmid = (q + 0.5) * deltaHue, ds = Math.sin(Hmid), dc = Math.cos(Hmid); let idet, u, v, t; for (let l = 0, i = 0; l < L; l++, i += 2) { idet = 1 / (ds * e2e1[i] + dc * e2e1[i + 1]); if ((t = idet * e2oe1[l]) > 0 && (u = idet * (ds * e2o[i] + dc * e2o[i + 1])) >= 0 && (v = idet * (ds * oe1[i] + dc * oe1[i + 1])) >= 0 && u + v <= 1) dat.push([Math.sign(idet), t]); } rtn[q] = dat; } return rtn; } export function gamutVolume(g) { let dH = 2 * Math.PI / g.hsteps, dL = 100 / g.Lsteps, tot = 0; for (let i = 0; i < g.Lsteps; i++) for (let j = 0; j < g.hsteps; j++) { const m = g.cylmap[i][j]; for (let k = 0; k < m.length; k++) tot += m[k][0] * m[k][1] * m[k][1]; } return tot * dL * dH / 2; }
29.69697
95
0.516156
93eb9d8433936f33e26791ec3217a7cf333773fb
1,258
js
JavaScript
app/src/systems/protagonistPawnChopTree.js
linonetwo/electron-react-game-dev-playground
8dfe78bc4a675cef030851e6b2786a4d82272441
[ "MIT" ]
null
null
null
app/src/systems/protagonistPawnChopTree.js
linonetwo/electron-react-game-dev-playground
8dfe78bc4a675cef030851e6b2786a4d82272441
[ "MIT" ]
1
2020-02-06T06:06:37.000Z
2020-02-06T06:06:37.000Z
app/src/systems/protagonistPawnChopTree.js
linonetwo/electron-react-game-dev-playground
8dfe78bc4a675cef030851e6b2786a4d82272441
[ "MIT" ]
null
null
null
/* eslint-disable no-param-reassign */ // @flow import { vDist } from 'vec-la-fp'; import type { SystemInput } from 'systems/typing'; import choppedBase from '~/entities/components/chopped'; import type { IChopped } from '~/entities/components/chopped'; import type { IAffectable } from '~/entities/components/affectable'; export default function protagonistPawnChopTree({ entities, keysDown, elapsedTime }: SystemInput) { if (keysDown.includes('Space')) { const protagonistPawn = entities.find(entity => entity['@type'] === 'protagonistPawn'); if (protagonistPawn) { const treeNearPawn: ?IAffectable = entities .filter(entity => 'position' in entity && 'debuff' in entity) .find(entity => vDist(entity.position, protagonistPawn.position) < protagonistPawn.baseOperationRange); if (treeNearPawn) { // can only have one chopped debuff const prevChoppedDebuff: ?IChopped = treeNearPawn.debuff.find(item => item['@type'] === 'chopped'); if (!prevChoppedDebuff) { treeNearPawn.debuff.push(choppedBase); } else { prevChoppedDebuff.choppedTime += elapsedTime; } } // console.warn(`treeNearPawn`, JSON.stringify(treeNearPawn, null, ' ')); } } }
40.580645
111
0.671701
93ebd94b3b8e6d14b018ebb472b942525fcfba4d
912
js
JavaScript
booking/src/main/webapp/resources/js/update_bookings.js
koenighotze/Hotel-Reservation-Tool
7d217d738bdca0d8ace45149190e8c9ff73b6d9c
[ "Apache-2.0" ]
6
2017-04-11T08:49:30.000Z
2020-06-10T08:59:39.000Z
booking/src/main/webapp/resources/js/update_bookings.js
koenighotze/Hotel-Reservation-Tool
7d217d738bdca0d8ace45149190e8c9ff73b6d9c
[ "Apache-2.0" ]
29
2015-08-28T20:51:06.000Z
2016-02-07T10:13:23.000Z
booking/src/main/webapp/resources/js/update_bookings.js
koenighotze/Hotel-Reservation-Tool
7d217d738bdca0d8ace45149190e8c9ff73b6d9c
[ "Apache-2.0" ]
2
2017-05-07T19:13:58.000Z
2020-05-19T18:42:20.000Z
var setupWs = function (config) { "use strict"; console.log("setting up websocket"); var ws = new WebSocket(config.webSocketBaseUrl() + "/booking/tracking"); ws.onopen = function(event) { onConnect(event); }; ws.onmessage = function(event) { onMessage(event); }; var onConnect = function(event) { console.log("Connected " + event); }; var onMessage = function(event) { updateBooking(event); }; var updateBooking = function(event) { var jsonObject = JSON.parse(event.data); var field = $('span#status_' + jsonObject.reservationNumber); if (field) { field .fadeOut('slow') .promise() .done(function() { field.text(jsonObject.newState); field.fadeIn('slow'); }); } }; };
24
77
0.515351
93ec55adaae39eec5146ad03c1727c3d85d8e065
701
js
JavaScript
src/components/Tips/TipView.js
Lianyulovely/react-basic
6df73c2e57cc0d720520afce343966705f65fb64
[ "MIT" ]
null
null
null
src/components/Tips/TipView.js
Lianyulovely/react-basic
6df73c2e57cc0d720520afce343966705f65fb64
[ "MIT" ]
null
null
null
src/components/Tips/TipView.js
Lianyulovely/react-basic
6df73c2e57cc0d720520afce343966705f65fb64
[ "MIT" ]
null
null
null
import React,{Component} from "react"; import "./tips.css"; export default class TipView extends Component{ constructor(props){ super(props); } render(){ return( <div className={this.props.tipShow?" alert alert-success alert-block fade in my-alert":"alert alert-success alert-block fade my-alert hide"}> <button data-dismiss="alert" className="close close-sm" type="button"> <i className="icon-remove"></i> </button> <h4 style={{"marginBottom":0}}> <i className="icon-ok-sign"></i>&nbsp; {this.props.tipText} </h4> </div> ) } }
31.863636
153
0.537803
93ed774ad3531fb22260e04200036ef02f70ccaf
1,790
js
JavaScript
example/stomp_sync.js
Fleischers/msb
65b639dbcefda0e46a3610f38e3ea268f1bce2df
[ "MIT" ]
null
null
null
example/stomp_sync.js
Fleischers/msb
65b639dbcefda0e46a3610f38e3ea268f1bce2df
[ "MIT" ]
null
null
null
example/stomp_sync.js
Fleischers/msb
65b639dbcefda0e46a3610f38e3ea268f1bce2df
[ "MIT" ]
null
null
null
var stompit = require('stompit'); var connectOptions = { // 'host': '172.28.23.93', 'host': 'stomp+ssl://b-06af7f46-7359-49b7-9124-ac37ea1c1892-1.mq.us-east-2.amazonaws.com', 'port': 61614, 'connectHeaders':{ 'host': '/', 'login': 'admin1', 'passcode': 'admin1admin2', 'heart-beat': '5000,5000' } // 'host': 'localhost', // 'port': '61613', // 'connectHeaders':{ // 'host': '/', // 'login': 'admin', // 'passcode': 'admin', // 'heart-beat': '5000,5000' // } }; // var client = stompit.connect(connectOptions, function(error, client) { console.log('connect ', client); if (error) { console.log('connection error', error) return; } var sendHeaders = { 'destination': '/topic/VirtualTopic.Test', 'content-type': 'text/plain' }; var frame = client.send(sendHeaders); frame.write('hello'); frame.end(); var subscribeHeaders1 = { 'destination': '/queue/Consumer.A.VirtualTopic.Test', 'ack': 'client-individual' }; var subscribeHeaders2 = { 'destination': '/queue/Consumer.B.VirtualTopic.Test', 'ack': 'client-individual' }; var subscribeHeaders = process.env.CLIENT2 ? subscribeHeaders2 : subscribeHeaders1; client.subscribe(subscribeHeaders, function(error, message) { if (error) { console.log('subscribe error ' + error.message); return; } message.readString('utf-8', function(error, body) { if (error) { console.log('read message error ' + error.message); return; } console.log('received message: ' + body); client.ack(message); // client.disconnect(); }); }); }); // client.on('connect', // // if (error) { // console.log('connect error ' + error.message); // return; // }
21.058824
92
0.591061
93edca99aa6fe1668440f399f048db4fc5244d03
1,125
js
JavaScript
component/Splash.js
jimju/BNDemo
6aa8c95eed160f112004240ee54e8dadf900a5d6
[ "Apache-2.0" ]
null
null
null
component/Splash.js
jimju/BNDemo
6aa8c95eed160f112004240ee54e8dadf900a5d6
[ "Apache-2.0" ]
null
null
null
component/Splash.js
jimju/BNDemo
6aa8c95eed160f112004240ee54e8dadf900a5d6
[ "Apache-2.0" ]
null
null
null
'use strict'; import React from 'react'; import { Dimensions, Image, InteractionManager, View, Text, BackAndroid, StyleSheet, } from 'react-native'; import TabComponent from './TabComponent'; var Dimen = require('Dimensions'); var ScreenWidth = Dimen.get('window').getWidth; var ScreenHeight = Dimen.get('window').getHeight; export default class Splash extends React.Component { constructor(props) { super(props); } componentDidMount() { const {navigator} = this.props; this.timer=setTimeout(() => { InteractionManager.runAfterInteractions(() => { navigator.resetTo({ component: TabComponent, name: 'TabComponent' }); }); }, 2500); } componentWillUnmount() { this.timer && clearTimeout(this.timer); } render(){ return(<View style={styles.container}> <Image source={require('../res/images/welcome.png')} style={styles.image}/> </View> ); } } var styles = StyleSheet.create({ container:{ flex:1, }, image:{ flex:1, width:ScreenWidth, height:ScreenHeight, } });
19.067797
53
0.618667
93ede72b4a3f7039518dfb6cede537da07ab9c14
329
js
JavaScript
src/services/index.js
stalniy/casl-feathersjs
110e6e29a79584b09cb7951616d4ed18e1c5b41b
[ "MIT" ]
34
2017-07-28T22:12:43.000Z
2021-11-18T11:53:36.000Z
src/services/index.js
stalniy/casl-feathersjs
110e6e29a79584b09cb7951616d4ed18e1c5b41b
[ "MIT" ]
10
2017-09-27T10:17:33.000Z
2020-11-06T16:25:53.000Z
src/services/index.js
stalniy/casl-feathersjs
110e6e29a79584b09cb7951616d4ed18e1c5b41b
[ "MIT" ]
9
2017-09-08T02:26:48.000Z
2022-01-06T12:13:24.000Z
const users = require('./users/users.service.js'); const comments = require('./comments/comments.service.js'); const posts = require('./posts/posts.service.js'); module.exports = function () { const app = this; // eslint-disable-line no-unused-vars app.configure(users); app.configure(comments); app.configure(posts); };
32.9
59
0.708207
93ee2f55c5f274ca2506f6da3a216013cd7bde6f
555
js
JavaScript
dist/cookie-js.min.js
IoTcat/cookie-js
4314d739594a4bcceb80898e3c9b8cd0594417bb
[ "MIT" ]
null
null
null
dist/cookie-js.min.js
IoTcat/cookie-js
4314d739594a4bcceb80898e3c9b8cd0594417bb
[ "MIT" ]
null
null
null
dist/cookie-js.min.js
IoTcat/cookie-js
4314d739594a4bcceb80898e3c9b8cd0594417bb
[ "MIT" ]
null
null
null
var cookie={set:function(e,n,t){if(t===undefined)var t=2400;var i=new Date;i.setTime(i.getTime()+t*24*60*60*1e3);document.cookie=e+"="+escape(n)+";expires="+i.toGMTString()+";path=/"},get:function(e){var n,t=new RegExp("(^| )"+e+"=([^;]*)(;|$)");if(n=document.cookie.match(t)){return unescape(n[2])}else{return null}},del:function(e){var n=new Date;n.setTime(n.getTime()-1);var t,i=new RegExp("(^| )"+e+"=([^;]*)(;|$)");if(t=document.cookie.match(i)){var o=unescape(t[2])}else{var o=null}if(o!=null){document.cookie=e+"="+o+";expires="+n.toGMTString()}}};
555
555
0.632432
93ee5f711339f491e0608172b2aaa150109fd4c0
5,263
js
JavaScript
src/services/playbookService.js
yingzhao-1/Sia-EventUI
ca371fe5fc282216a0207867a3a77a2f7b6c21ec
[ "MIT" ]
null
null
null
src/services/playbookService.js
yingzhao-1/Sia-EventUI
ca371fe5fc282216a0207867a3a77a2f7b6c21ec
[ "MIT" ]
null
null
null
src/services/playbookService.js
yingzhao-1/Sia-EventUI
ca371fe5fc282216a0207867a3a77a2f7b6c21ec
[ "MIT" ]
null
null
null
import { DateTime } from 'luxon' import ByPath from 'object-path' import * as eventTypeActions from 'actions/eventTypeActions' import * as eventActions from 'actions/eventActions' export const IsBootstrapNeeded = (eventType, isFetching, isError) => !eventType && !(isFetching || isError) export const BootstrapIfNeeded = ({eventTypeId, eventType, isFetching, isError, dispatch}) => { if (IsBootstrapNeeded(eventType, isFetching, isError)) { dispatch(eventTypeActions.fetchEventType(eventTypeId)) } } export const selectSourceObject = (sourceObjectEnum, event, ticket, eventType, engagement) => { switch (sourceObjectEnum) { case 0: return event case 1: return ticket case 2: return eventType case 3: return engagement default: return null // not sure if there's a better behavior for undefined enum } } export const GetComparisonValue = (condition) => { switch (condition.dataFormat) { case 0: // string return condition.comparisonValue case 1: // datetime return condition.dateTimeComparisonValue ? DateTime.fromISO(condition.dateTimeComparisonValue) : condition.dateTimeComparisonValue default: // int return condition.integerComparisonValue } } export const testableTestByConditionType = (getComparisonValue) => (condition) => { const comparisonValue = getComparisonValue(condition) const value = condition ? condition.value : null switch (condition.conditionType) { // contains case 1: return value && value.includes(comparisonValue) // has value case 2: return !!value // greater than case 3: return value && (value > comparisonValue) // less than case 4: return value && (comparisonValue > value) // equals default: return value === comparisonValue } } export const TestByConditionType = testableTestByConditionType(GetComparisonValue) export const testableTestCondition = (testByConditionType) => (condition) => { const testResult = testByConditionType(condition) return condition.AssertionType === 0 ? !testResult : testResult } export const TestCondition = testableTestCondition(TestByConditionType) export const testableTestConditionSet = (select, testCondition) => (event, ticket, eventType, engagement) => (conditionSet) => { const conditionsWithValue = conditionSet.conditions ? conditionSet.conditions .map(condition => condition.conditionSource ? ({ ...condition, value: ByPath.get( select(condition.conditionSource.sourceObject, event, ticket, eventType, engagement), condition.conditionSource.key ) }) : ({ ...condition, value: null }) ) : [] const metConditionsCount = conditionsWithValue.map(testCondition).filter(b => b).length switch (conditionSet.type) { case 0: // Any of return metConditionsCount > 0 case 1: // All of return metConditionsCount === conditionsWithValue.length case 2: // noneOf return metConditionsCount === 0 default: // Not All Of return metConditionsCount < conditionsWithValue.length } } export const TestConditionSet = testableTestConditionSet(selectSourceObject, TestCondition) export const testableFillTemplate = (selectSource) => (template, event, ticket, eventType, engagement) => { if (!template || !template.pattern) return '' const templateSourcesWithData = template.sources ? template.sources.map( source => Object.assign({}, source, {dataValue: ByPath.get( selectSource(source.sourceObject, event, ticket, eventType, engagement), source.key )}) ) : [] let filledTemplate = template.pattern templateSourcesWithData.forEach(source => { filledTemplate = filledTemplate.replace('${' + source.name + '}', source.dataValue) }) return filledTemplate } export const fillTemplate = testableFillTemplate(selectSourceObject) export const LoadTextFromEvent = (event, eventType, ticket, engagement) => { return HasValidDisplayTemplatePattern(eventType) ? fillTemplate(eventType.displayTemplate, event, ticket, eventType, engagement) : HasValidDisplayText(event.data) ? event.data.DisplayText : HasValidName(eventType) ? eventType.name : HasValidData(event) ? JSON.stringify(event.data) : 'This event has no text' } const HasValidDisplayTemplatePattern = (eventType) => { return eventType && eventType.displayTemplate && eventType.displayTemplate.pattern && eventType.displayTemplate.pattern.length > 0 } const HasValidDisplayText = (data) => { return data && data.DisplayText && data.DisplayText.length > 0 } const HasValidName = (eventType) => { return eventType && eventType.name && eventType.name.length > 0 } const HasValidData = (event) => { return !!(event.data) } export const publishEvent = (incidentId, filledTemplate) => () => (dispatch) => { const parsedTemplate = JSON.parse(filledTemplate) dispatch(eventActions.postEvent(incidentId, parsedTemplate.id, parsedTemplate.data)) }
36.047945
132
0.683641
93eea06939f86cc0f72388ffed552840641aacb9
427
js
JavaScript
src/routes/projects.route.js
conholo/PersonalWebsite
61185fe050591672c0a7f54b389348917f7b6e0b
[ "Apache-2.0" ]
null
null
null
src/routes/projects.route.js
conholo/PersonalWebsite
61185fe050591672c0a7f54b389348917f7b6e0b
[ "Apache-2.0" ]
null
null
null
src/routes/projects.route.js
conholo/PersonalWebsite
61185fe050591672c0a7f54b389348917f7b6e0b
[ "Apache-2.0" ]
null
null
null
const express = require('express'); const router = express.Router(); const projectsController = require('../controllers/projects.controller'); router.get("/", projectsController.get_projects_page); router.get("/pathfinder", projectsController.get_pathfinder_page); router.get('/2D_engine', projectsController.get_2D_engine_page); router.get('/cg_projects', projectsController.get_cg_projects_page); module.exports = router;
38.818182
73
0.796253
93f14491aff275657610b79d6791808e2e91441b
963
js
JavaScript
j1.js
saishushma/saishushma.github.io
df3599b6d6d1bb39b2f0333224b70ff8b497777d
[ "Apache-2.0" ]
null
null
null
j1.js
saishushma/saishushma.github.io
df3599b6d6d1bb39b2f0333224b70ff8b497777d
[ "Apache-2.0" ]
null
null
null
j1.js
saishushma/saishushma.github.io
df3599b6d6d1bb39b2f0333224b70ff8b497777d
[ "Apache-2.0" ]
null
null
null
function toggle_visibility(id1,id2,id3,id4,id5) { var e = document.getElementById(id1); e.style.display = 'block'; var f=document.getElementById(id2); f.style.display= 'none'; var g=document.getElementById(id3); g.style.display= 'none'; var h=document.getElementById(id4); h.style.display= 'none'; var i=document.getElementById(id5); i.style.display= 'none'; } function starttime() { const today = new Date(); let hr = today.getHours(); let min = today.getMinutes(); let sec = today.getSeconds(); min = checktime(min); sec = checktime(sec); //document.getElementById('d').innerHTML = hr + ":" + min + ":" + sec; var date = today.getFullYear()+'-'+(today.getMonth()+1)+'-'+today.getDate(); document.getElementById('d').innerHTML = hr + ":" + min + ":" + sec+" &nbsp;&nbsp;&nbsp;&nbsp; "+date; setTimeout(starttime, 1000); } function checktime(j) { if (j < 10) {j = "0" + j}; return j; }
32.1
108
0.623053
c4b812cd5b9861b883190772d63b75853cbb86fd
1,486
js
JavaScript
AlarmAppDemo/node_modules/auth-header/src/format.js
avatar-use-cases/CCO-LD-Avatar
ec98761657245e9ef33afce5caa3b107209c36e0
[ "Apache-2.0" ]
2
2019-03-04T13:33:54.000Z
2019-04-04T13:29:02.000Z
node_modules/auth-header/src/format.js
Arquisoft/dechat_es2a
459dc513b8bbdff37d5c22945e4e1230dc881511
[ "MIT" ]
29
2019-02-15T08:04:06.000Z
2022-03-02T03:21:50.000Z
node_modules/auth-header/src/format.js
sunchang0124/sunchang0124.github.io
4a3cd5ab29f00f14674fc2d9382f30821b37f1de
[ "MIT" ]
5
2019-04-01T12:27:20.000Z
2020-08-14T13:13:33.000Z
// @flow import {quote, isToken, isScheme} from './util'; const xxx = (key: string) => (value: string): string => `${key}=${value && !isToken(value) ? quote(value) : value}`; const build = ( params: Array<[string, string | Array<string>]>, ): Array<string> => { return params.reduce((prev, [key, values]) => { const transform = xxx(key); if (!isToken(key)) { throw new TypeError(); } if (Array.isArray(values)) { return [...prev, ...values.map(transform)]; } return [...prev, transform(values)]; }, []); }; type Params = | Array<[string, string | Array<string>]> | {[string]: string | Array<string>}; const challenge = (params: Params, options) => { if (Array.isArray(params)) { return build(params); } else if (typeof params === 'object') { const entries: {[string]: string | Array<string>} = params; return challenge( Object.keys(params).map((key) => [key, entries[key]]), options, ); } throw new TypeError(); }; export default (scheme: string, token: ?string, params: Params): string => { const obj = typeof scheme === 'string' ? {scheme, token, params} : scheme; if (typeof obj !== 'object') { throw new TypeError(); } else if (!isScheme(obj.scheme)) { throw new TypeError('Invalid scheme.'); } return [ obj.scheme, ...(typeof obj.token !== 'undefined' ? [obj.token] : []), ...(typeof obj.params !== 'undefined' ? challenge(obj.params) : []), ].join(' '); };
27.518519
76
0.583445
c4b8b441e957bef68926073dc5bbebccdd4ec9de
271
js
JavaScript
models/blog.model.js
subhadeep-bis/UNBLOGGED
6543ed60fcb6caf06c39c0be2983308600e13bff
[ "MIT" ]
1
2019-06-23T08:53:27.000Z
2019-06-23T08:53:27.000Z
models/blog.model.js
subhadeep-bis/UNBLOGGED
6543ed60fcb6caf06c39c0be2983308600e13bff
[ "MIT" ]
null
null
null
models/blog.model.js
subhadeep-bis/UNBLOGGED
6543ed60fcb6caf06c39c0be2983308600e13bff
[ "MIT" ]
1
2019-10-21T06:03:14.000Z
2019-10-21T06:03:14.000Z
const mongoose = require('mongoose'); const Schema = mongoose.Schema; let blogSchema = new Schema({ title: String, image: String, body: String, created: {type: Date, default: Date.now} }); // Export this model module.exports = mongoose.model('Blog', blogSchema);
22.583333
52
0.704797
c4bb0ad6a5a0a5885f7958e50ac9dfefa89c6188
6,896
js
JavaScript
app/viewmodels/thanks.js
reengo/rinjenph
db9c6b5ae72a031e5a8a362d374281e77b75a359
[ "MIT" ]
null
null
null
app/viewmodels/thanks.js
reengo/rinjenph
db9c6b5ae72a031e5a8a362d374281e77b75a359
[ "MIT" ]
null
null
null
app/viewmodels/thanks.js
reengo/rinjenph
db9c6b5ae72a031e5a8a362d374281e77b75a359
[ "MIT" ]
null
null
null
define(['plugins/http', 'durandal/app', 'knockout'], function (http, app, ko) { return { displayName: 'Thanks', contactName: ko.observable(''), contactEmail: ko.observable(''), contactMessage: ko.observable(''), alertStyle: ko.observable('info'), flash:ko.observable(''), sending:ko.observable(false), activate: function () { }, attached: function(){ }, select: function(item) { item.viewUrl = 'views/detail'; app.showDialog(item); }, // canDeactivate: function () { // //the router's activator calls this function to see if it can leave the screen // return app.showMessage('Are you sure you want to leave this page?', 'Navigate', ['Yes', 'No']); // } getProfile: function(){ var that = this; $.ajax({ url:'https://graph.facebook.com/v2.3/me?fields=picture&access_token=' + this.settings.facebook, jsonp: "callback", dataType: "jsonp", data: { format: "json" }, success: function( response ) { console.log({'facebook':response.data}); that.profile(response.data); } }); }, getFacebookImages: function(){ var that = this; $.ajax({ url: "https://graph.facebook.com/v2.3/me/photos?limit=5&access_token=" + this.settings.facebook, jsonp: "callback", dataType: "jsonp", data: { format: "json"}, success: function( response ) { console.log({'facebook':response.data}); that.facebook(response.data); } }); }, getInstagramImages: function(hashtag, access_token){ var that = this, url = "https://api.instagram.com/v1/tags/" + hashtag + "/media/recent?access_token=" + access_token; $.ajax({ url: url, jsonp: "callback", dataType: "jsonp", data: { format: "json" }, success: function( response ) { if(response.data){ var mapped = $.map(response.data, function(item){ var image = item.images.standard_resolution.url; var profile = item.picture; return { user: profile, image: image} }); for(var i=0;i<response.data.length;i++){ that.images.push(response.data[i]); } } } }); }, sendMail: function(){ var that = this; this.sending(true); $.ajax({ type: 'POST', url: 'https://mandrillapp.com/api/1.0/messages/send.json', data: { 'key': 'Ig-CsRsaxFbohsLl0eMcEQ', 'message': { 'from_email': 'me@ringo.ph', 'to': [ { 'email': 'me@ringo.ph', 'name': '', 'type': 'to' }, { 'email': this.contactEmail(), 'name': this.contactName(), 'type': 'to' } ], 'autotext': 'true', 'subject': 'Wedding Details Inquiry', 'html': 'Thank you for your feedback <strong>' + this.contactName() + '</strong>,<br /><br /> Jennifer and Ringo will be delighted to read these awesome feedback.. Thank you so much.<br /><br />Your Message: <br /><br />' + this.contactMessage() + '<br /><br />Regards,<br /><strong>Jennifer & Ringo</strong><br />wedding couple' } } }).done(function(response) { $(response).each(function(i, el){ if(el.status == 'sent'){ that.flash('<strong>You have just sent your inquiry...</strong> check your email, chances are, the couple had already responded :D'); that.alertStyle('alert-success'); }else{ that.alertStyle('alert-danger'); that.flash('<strong>Tsktsk!</strong> Something went wrong. Please try again later.'); } }); that.sending(false); }) }, _sendMail: function(){ console.log('sent'); var self = this; var name = this.contactName(), email = this.contactEmail(), subject = 'Rinjen Inquiry', msg = this.contactMessage(), dataString = 'name=' + name + '&email=' + email + '&subject=' + subject + '&message=' + msg; if (this.validateEmail(email) && (msg.length > 1) && (name.length > 1) && (subject.length > 1) ){ $.ajax({ type: "POST", url: "/mail.php", data: dataString, success: function(response){ console.log(response); self.flash('<strong>Message Sent!</strong> Thank you for stopping by.'); self.alertStyle('alert-success'); } }); } else{ this.alertStyle('alert-danger'); this.flash('<strong>Oops!</strong> Something went wrong. Please try again later.'); } return false; }, validateEmail: function(emailAddress) { var pattern = new RegExp(/^((([a-z]|\d|[!#\$%&'\*\+\-\/=\?\^_`{\|}~]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])+(\.([a-z]|\d|[!#\$%&'\*\+\-\/=\?\^_`{\|}~]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])+)*)|((\x22)((((\x20|\x09)*(\x0d\x0a))?(\x20|\x09)+)?(([\x01-\x08\x0b\x0c\x0e-\x1f\x7f]|\x21|[\x23-\x5b]|[\x5d-\x7e]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(\\([\x01-\x09\x0b\x0c\x0d-\x7f]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF]))))*(((\x20|\x09)*(\x0d\x0a))?(\x20|\x09)+)?(\x22)))@((([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])*([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])))\.)+(([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])*([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])))\.?$/i); return pattern.test(emailAddress); } }; });
47.232877
947
0.454901
c4bc0b60a15a3f6dc11af3a15f8d6528a7a158b5
1,237
js
JavaScript
app.js
anoopsrma/dashain-bot
122c0d38168b93a03c4f07b4bce5aa4c0cb268ff
[ "MIT" ]
null
null
null
app.js
anoopsrma/dashain-bot
122c0d38168b93a03c4f07b4bce5aa4c0cb268ff
[ "MIT" ]
null
null
null
app.js
anoopsrma/dashain-bot
122c0d38168b93a03c4f07b4bce5aa4c0cb268ff
[ "MIT" ]
null
null
null
const express = require('express') require('dotenv').config(); const Snoowrap = require('snoowrap'); const Snoostorm = require('snoostorm'); const app = express() app.get('/', function (req, res) { res.sendFile(__dirname + '/index.html'); }) app.listen(process.env.PORT || 3000, function () { console.log('Example app listening on port 3000!') }) // Build Snoowrap and Snoostorm clients const r = new Snoowrap({ userAgent: 'reddit-bot-example-node', clientId: process.env.CLIENT_ID, clientSecret: process.env.CLIENT_SECRET, username: process.env.REDDIT_USER, password: process.env.REDDIT_PASS }); const client = new Snoostorm(r); // Configure options for stream: subreddit & results per query const streamOpts = { subreddit: 'subredditdrama', results: 25 }; // Create a Snoostorm CommentStream with the specified options const comments = client.CommentStream(streamOpts); // eslint-disable-line // On comment, perform whatever logic you want to do comments.on('comment', (comment) => { console.log(comment.body.search(/dashain/i)); if (comment.body.search(/dashain/i) != -1 ) { comment.reply('demo bot for da$hain :)'); } else{ console.log(comment.body); } });
28.113636
73
0.687146
c4bc212e6e9c073beb5d31efc261e5f3987bb710
3,688
js
JavaScript
src/components/Header/header.js
Rouncer27/airdrie-angel-gatsby
017481fe987f28e0e168ccaec5b69d33cde78b2b
[ "MIT" ]
1
2019-02-18T19:16:40.000Z
2019-02-18T19:16:40.000Z
src/components/Header/header.js
Rouncer27/airdrie-angel-gatsby
017481fe987f28e0e168ccaec5b69d33cde78b2b
[ "MIT" ]
8
2020-03-27T16:22:43.000Z
2020-03-27T16:34:22.000Z
src/components/Header/header.js
Rouncer27/airdrie-angel-gatsby
017481fe987f28e0e168ccaec5b69d33cde78b2b
[ "MIT" ]
null
null
null
import { Link } from "gatsby"; import PropTypes from "prop-types"; import React, { Component } from "react"; import styled from "styled-components"; import Logo from "./Nav/NavLogo"; import NavSocial from "./Nav/NavSocial"; import Navigation from "./Nav/Navigation"; import { StandardWrapper } from "../styles/Commons/Wrappers"; const StyledHeader = styled.header` position: relative; padding: 5rem 0; background: linear-gradient( to right, ${props => props.theme.white} 0%, ${props => props.theme.teal} 100% ); @media (min-width: ${props => props.theme.bpTablet}) { padding: 3rem 0 2rem; } `; const LogoWrapper = styled.div` display: flex; align-items: center; flex-wrap: wrap; justify-content: center; width: 100%; @media (min-width: ${props => props.theme.bpTablet}) { width: 100%; } `; const NavWrapper = styled.div` display: flex; align-items: center; flex-wrap: wrap; justify-content: center; width: 100%; margin-top: 5rem; @media (min-width: ${props => props.theme.bpTablet}) { width: 100%; margin-top: 2.5rem; } .mobile-toggle-button { display: flex; flex-wrap: wrap; justify-content: center; align-items: center; position: fixed; top: 0.25rem; left: 0.25rem; width: 7.5rem; height: 7.5rem; margin: 0 auto; padding: 0; background: ${props => props.theme.navyBlue}; border: 0.1rem solid ${props => props.theme.white}; box-shadow: 0.25rem 0.25rem 0.25rem ${props => props.theme.black}; color: ${props => props.theme.white}; text-align: center; z-index: 99999999; &::before, &::after { display: block; position: absolute; right: 0; left: 0; width: 80%; height: 0.2rem; margin: 0 auto; transform: rotate(0); transform-origin: center center; transition: all 0.2s ease; background-color: ${props => props.theme.white}; content: ""; } &::before { top: 1rem; } &::after { bottom: 1rem; } &:hover { cursor: pointer; &::before { top: 0.5rem; } &::after { bottom: 0.5rem; } } &:focus { outline: none; } @media (min-width: ${props => props.theme.bpTablet}) { display: none; } } &.mobile-acive-open { .mobile-toggle-button { background: ${props => props.theme.teal}; color: ${props => props.theme.teal}; &::before { top: 50%; transform: translateY(-50%) rotate(135deg); } &::after { bottom: 50%; transform: translateY(50%) rotate(-135deg); } } } `; const MenuBtn = styled.button``; class Header extends Component { constructor(props) { super(props); this.toggleMobileNav = this.toggleMobileNav.bind(this); this.state = { navOpen: false }; } toggleMobileNav() { this.setState(prevState => { return { navOpen: !prevState.navOpen }; }); } render() { return ( <StyledHeader> <StandardWrapper> <LogoWrapper> <Logo /> </LogoWrapper> <NavWrapper className={ this.state.navOpen ? "mobile-acive-open" : "mobile-acive-closed" } > <MenuBtn className="mobile-toggle-button" onClick={this.toggleMobileNav} > Menu </MenuBtn> {/* <NavSocial /> */} <Navigation isOpen={this.state.navOpen} /> </NavWrapper> </StandardWrapper> </StyledHeader> ); } } export default Header;
20.836158
78
0.556128
c4bc498964c55963fa2d1e53458e79a31caceb84
33
js
JavaScript
src/base/vary-ui/components/editor/index.js
IronPans/vary-admin
15790da1f1cfa301f5fbbea8acd37feba2f73ef1
[ "MIT" ]
28
2018-09-11T12:11:23.000Z
2020-05-19T06:22:14.000Z
src/base/vary-ui/components/editor/index.js
IronPans/vary-admin
15790da1f1cfa301f5fbbea8acd37feba2f73ef1
[ "MIT" ]
2
2019-04-26T07:55:34.000Z
2020-01-22T13:02:11.000Z
src/base/vary-ui/components/editor/index.js
IronPans/vary-admin
15790da1f1cfa301f5fbbea8acd37feba2f73ef1
[ "MIT" ]
8
2018-07-09T08:16:23.000Z
2021-01-28T14:39:48.000Z
export {default} from './editor';
33
33
0.69697
c4bcc56d92e6cbe721b7efd350ecc39150bb7de9
7,112
js
JavaScript
theme.old/dist/components/productFilter/attributeFilter.js
timonjagi/cezerin2
6ce921f31c6577ea9171782ddb7c0142e0a54efc
[ "MIT" ]
null
null
null
theme.old/dist/components/productFilter/attributeFilter.js
timonjagi/cezerin2
6ce921f31c6577ea9171782ddb7c0142e0a54efc
[ "MIT" ]
null
null
null
theme.old/dist/components/productFilter/attributeFilter.js
timonjagi/cezerin2
6ce921f31c6577ea9171782ddb7c0142e0a54efc
[ "MIT" ]
null
null
null
"use strict"; function _typeof(obj) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (obj) { return typeof obj; } : function (obj) { return obj && "function" == typeof Symbol && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }, _typeof(obj); } Object.defineProperty(exports, "__esModule", { value: true }); exports["default"] = void 0; var _react = _interopRequireDefault(require("react")); function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; } function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } function _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); Object.defineProperty(Constructor, "prototype", { writable: false }); return Constructor; } function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function"); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, writable: true, configurable: true } }); Object.defineProperty(subClass, "prototype", { writable: false }); if (superClass) _setPrototypeOf(subClass, superClass); } function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); } function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = _getPrototypeOf(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = _getPrototypeOf(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return _possibleConstructorReturn(this, result); }; } function _possibleConstructorReturn(self, call) { if (call && (_typeof(call) === "object" || typeof call === "function")) { return call; } else if (call !== void 0) { throw new TypeError("Derived constructors may only return object or undefined"); } return _assertThisInitialized(self); } function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; } function _isNativeReflectConstruct() { if (typeof Reflect === "undefined" || !Reflect.construct) return false; if (Reflect.construct.sham) return false; if (typeof Proxy === "function") return true; try { Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); return true; } catch (e) { return false; } } function _getPrototypeOf(o) { _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf : function _getPrototypeOf(o) { return o.__proto__ || Object.getPrototypeOf(o); }; return _getPrototypeOf(o); } function _defineProperty(obj, key, value) { if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; } var AttributeValue = /*#__PURE__*/function (_React$Component) { _inherits(AttributeValue, _React$Component); var _super = _createSuper(AttributeValue); function AttributeValue(props) { var _this; _classCallCheck(this, AttributeValue); _this = _super.call(this, props); _defineProperty(_assertThisInitialized(_this), "onChange", function (event) { var _this$props = _this.props, attributeName = _this$props.attributeName, valueName = _this$props.valueName, setFilterAttribute = _this$props.setFilterAttribute, unsetFilterAttribute = _this$props.unsetFilterAttribute; var checked = event.target.checked; _this.setState({ checked: checked }); if (checked) { setFilterAttribute(attributeName, valueName); } else { unsetFilterAttribute(attributeName, valueName); } }); _this.state = { checked: props.checked }; return _this; } _createClass(AttributeValue, [{ key: "componentWillReceiveProps", value: function componentWillReceiveProps(nextProps) { if (nextProps.checked !== this.props.checked) { this.setState({ checked: nextProps.checked }); } } }, { key: "render", value: function render() { var _this$props2 = this.props, valueName = _this$props2.valueName, count = _this$props2.count; var isDisabled = count === 0; var classChecked = this.state.checked ? "attribute-checked" : ""; var classDisabled = isDisabled ? "attribute-disabled" : ""; return /*#__PURE__*/_react["default"].createElement("label", { className: classChecked + " " + classDisabled }, /*#__PURE__*/_react["default"].createElement("input", { type: "checkbox", disabled: isDisabled, onChange: this.onChange, checked: this.state.checked }), valueName); } }]); return AttributeValue; }(_react["default"].Component); var AttributeSet = function AttributeSet(_ref) { var attribute = _ref.attribute, setFilterAttribute = _ref.setFilterAttribute, unsetFilterAttribute = _ref.unsetFilterAttribute; var values = attribute.values.map(function (value, index) { return /*#__PURE__*/_react["default"].createElement(AttributeValue, { key: index, attributeName: attribute.name, valueName: value.name, checked: value.checked, count: value.count, setFilterAttribute: setFilterAttribute, unsetFilterAttribute: unsetFilterAttribute }); }); return /*#__PURE__*/_react["default"].createElement("div", { className: "attribute" }, /*#__PURE__*/_react["default"].createElement("div", { className: "attribute-title" }, attribute.name), values); }; var AttributeFilter = function AttributeFilter(_ref2) { var attributes = _ref2.attributes, setFilterAttribute = _ref2.setFilterAttribute, unsetFilterAttribute = _ref2.unsetFilterAttribute; var attributeSets = attributes.map(function (attribute, index) { return /*#__PURE__*/_react["default"].createElement(AttributeSet, { key: index, attribute: attribute, setFilterAttribute: setFilterAttribute, unsetFilterAttribute: unsetFilterAttribute }); }); return /*#__PURE__*/_react["default"].createElement("div", { className: "attribute-filter" }, attributeSets); }; var _default = AttributeFilter; exports["default"] = _default;
49.048276
452
0.700787
c4c03aca2e57144263bc08275d4a16beb83bc5aa
1,746
js
JavaScript
server_apply/src/app.js
Saeed1989/marn-mean-web-mobile-boilerplate
f346dd1e81721cf8d08e9704014ac6630927fbce
[ "MIT" ]
null
null
null
server_apply/src/app.js
Saeed1989/marn-mean-web-mobile-boilerplate
f346dd1e81721cf8d08e9704014ac6630927fbce
[ "MIT" ]
null
null
null
server_apply/src/app.js
Saeed1989/marn-mean-web-mobile-boilerplate
f346dd1e81721cf8d08e9704014ac6630927fbce
[ "MIT" ]
null
null
null
const express = require("express"); const configureRoutes = require("./controllers"); const { handleRequest, handleError } = require("./middlewares"); const cors = require("cors"); const helmet = require("helmet"); const rateLimit = require("express-rate-limit"); const pino = require("pino-http")(); require("dotenv").config(); const compression = require("compression"); const swaggerUI = require("swagger-ui-express"); const limiter = rateLimit({ windowMs: 15 * 60 * 1000, // 15 minutes max: 1000, // limit each IP to 1000 requests per windowMs }); const app = express(); app.use(compression()); app.use(cors()); app.use(limiter); app.use(express.json()); app.use(helmet()); app.use(pino); app.use(handleRequest); const swaggerDocument = require("./swagger.json"); const swaggerDocumentCat = require("./swagger-paths/category-path-swagger.json"); const swaggerDocumentData = require("./swagger-paths/data-path-swagger.json"); const swaggerDocumentResource = require("./swagger-paths/resource-path-swagger.json"); const swaggerDocumentRole = require("./swagger-paths/role-path-swagger.json"); const swaggerDocumentPermission = require("./swagger-paths/permission-path-swagger.json"); const swaggerDocumentLogin = require("./swagger-paths/login-path-swagger.json"); swaggerDocument.paths = { ...swaggerDocument.paths, ...swaggerDocumentCat.paths, ...swaggerDocumentData.paths, ...swaggerDocumentResource.paths, ...swaggerDocumentRole.paths, ...swaggerDocumentPermission.paths, ...swaggerDocumentLogin.paths, }; app.use("/api-docs", swaggerUI.serve, swaggerUI.setup(swaggerDocument)); try { configureRoutes(app); } catch (err) { handleError(err); } // configureRoutes(app); app.use(handleError); module.exports = app;
32.333333
90
0.737113
c4c060107073afb356f8cb7fad65f2000ecf6613
1,238
js
JavaScript
packages/fyndiq-component-brand/src/index.test.js
fyndiq/fyndiq-ui
c8b0e44157b764f94bb0a945f82309ff04e61f0e
[ "MIT" ]
40
2017-05-12T13:45:37.000Z
2021-12-23T09:46:05.000Z
packages/fyndiq-component-brand/src/index.test.js
fyndiq/fyndiq-ui
c8b0e44157b764f94bb0a945f82309ff04e61f0e
[ "MIT" ]
16
2017-04-18T13:43:08.000Z
2020-01-16T15:04:36.000Z
packages/fyndiq-component-brand/src/index.test.js
fyndiq/fyndiq-ui
c8b0e44157b764f94bb0a945f82309ff04e61f0e
[ "MIT" ]
3
2018-04-17T04:49:25.000Z
2020-01-16T16:21:46.000Z
import React from 'react' import { shallow } from 'enzyme' import FyndiqLogo, { Square } from './' describe('fyndiq-component-brand', () => { it('should be rendered without props', () => { expect(shallow(<FyndiqLogo />)).toMatchSnapshot() }) it('should be rendered in different types', () => { expect(shallow(<FyndiqLogo type="outline" />)).toMatchSnapshot() expect(shallow(<FyndiqLogo type="bw" />)).toMatchSnapshot() expect(shallow(<FyndiqLogo type="outline-bw" />)).toMatchSnapshot() expect(shallow(<FyndiqLogo type="outline-transp" />)).toMatchSnapshot() expect(shallow(<FyndiqLogo type="outline-transp-bw" />)).toMatchSnapshot() }) it('should have a className prop', () => { expect(shallow(<FyndiqLogo className="testClass" />)).toMatchSnapshot() }) it('should have a tagline', () => { expect(shallow(<FyndiqLogo>Hello</FyndiqLogo>)).toMatchSnapshot() }) it('should have a taglineSize prop', () => { expect( shallow(<FyndiqLogo taglineSize={5.5}>Hello</FyndiqLogo>), ).toMatchSnapshot() }) it('should exist in square version', () => { expect(shallow(<Square />)).toMatchSnapshot() expect(shallow(<Square type="outline" />)).toMatchSnapshot() }) })
32.578947
78
0.655089
c4c1fcebe6ad94cd5b4de840d25f46600db9f3c0
522
js
JavaScript
src/elements/button/index.js
AkimaLunar/ceryl-design-seed
82e6eb6793729a9c4f5cd7ed9535ee8e314312f0
[ "MIT" ]
2
2018-06-24T21:02:26.000Z
2020-07-29T23:13:36.000Z
src/elements/button/index.js
AkimaLunar/ceryl-design-seed
82e6eb6793729a9c4f5cd7ed9535ee8e314312f0
[ "MIT" ]
4
2018-06-23T19:16:30.000Z
2019-08-14T02:07:46.000Z
src/elements/button/index.js
AkimaLunar/ceryl-design-seed
82e6eb6793729a9c4f5cd7ed9535ee8e314312f0
[ "MIT" ]
null
null
null
import React from 'react' import PropTypes from 'prop-types' import { withSpacing } from 'Utilities/spacing' import { withStyles } from 'Utilities/styles' import { constructStyles } from './styles' const Button = ({ children, onClick, className }) => ( <button className={className} onClick={onClick}> {children} </button> ) Button.propTypes = { children: PropTypes.node, className: PropTypes.string, onClick: PropTypes.func } export default withSpacing(withStyles(Button)(constructStyles))
26.1
63
0.714559
c4c2db0193fb90afcb54974a74102e3fa31db165
145
js
JavaScript
dist/message/string/and.js
dikac/t-array
83fae32baabba25bca2f22fa2f55684123299cfb
[ "MIT" ]
null
null
null
dist/message/string/and.js
dikac/t-array
83fae32baabba25bca2f22fa2f55684123299cfb
[ "MIT" ]
null
null
null
dist/message/string/and.js
dikac/t-array
83fae32baabba25bca2f22fa2f55684123299cfb
[ "MIT" ]
null
null
null
import AndObject from "../and"; export default function And(messages) { return AndObject(messages).message; } //# sourceMappingURL=and.js.map
29
39
0.744828
c4c2de4fd141be6787480e1a51363fe84aec1312
553
js
JavaScript
src/components/contact-me.js
kdabug/gatsby-portfolio
c73f04e445f3dda1cf7cd9408543e170aacca53e
[ "MIT" ]
null
null
null
src/components/contact-me.js
kdabug/gatsby-portfolio
c73f04e445f3dda1cf7cd9408543e170aacca53e
[ "MIT" ]
2
2021-09-21T16:41:21.000Z
2022-02-27T11:04:39.000Z
src/components/contact-me.js
kdabug/gatsby-portfolio
c73f04e445f3dda1cf7cd9408543e170aacca53e
[ "MIT" ]
null
null
null
import React from "react" import "./contact-me.scss" import ContactList from "./contact-list" import ContactForm from "./contact-form" const Contacts = () => { return ( <section id="#contact-me" className="section"> <div className="contact-container"> <h1 id="contact-me" className="contact-me-title"> contact me </h1> <div className="contact-content-section"> <ContactList location="section" /> <ContactForm /> </div> </div> </section> ) } export default Contacts
24.043478
57
0.605787
c4c3a9bdb9367ef62151a490a07480e0ceab09bc
274
js
JavaScript
staticfiles/main.js
Altaf-H-Miazee/BlogApp-Django
4245729352f5ce1180f6ba3b4e7cc6650ffb8358
[ "MIT" ]
1
2020-10-06T16:23:35.000Z
2020-10-06T16:23:35.000Z
staticfiles/main.js
hosenmdaltaf/BlogApp-Django
4245729352f5ce1180f6ba3b4e7cc6650ffb8358
[ "MIT" ]
null
null
null
staticfiles/main.js
hosenmdaltaf/BlogApp-Django
4245729352f5ce1180f6ba3b4e7cc6650ffb8358
[ "MIT" ]
null
null
null
const Readmorebtn = document.querySelector('.Read-more-btn'); const text = document.querySelector('.text'); Readmorebtn.addEventListener('click',(e)=>{ if(e.target.className='Read-more-btn'){ text.classList.toggle('showmore'); } } )
10.148148
61
0.624088
c4c3b59f5ab17d444746b1403963b78d10c9405b
214
js
JavaScript
public/assets/updates.js
michaelrhodes/wqst
9ee7768fde17e82fba6081f25d69dd59591b433b
[ "MIT" ]
null
null
null
public/assets/updates.js
michaelrhodes/wqst
9ee7768fde17e82fba6081f25d69dd59591b433b
[ "MIT" ]
null
null
null
public/assets/updates.js
michaelrhodes/wqst
9ee7768fde17e82fba6081f25d69dd59591b433b
[ "MIT" ]
null
null
null
var content = document.querySelector('#content') var updates = new EventSource('/updates') updates.addEventListener('message', function(message) { content.innerHTML = message.data .replace(/=\|=/g, '\n') })
26.75
55
0.700935
c4c48bea926dac78c88ae5febaec5ac693d6f976
866
js
JavaScript
app/server.js
imnutz/sam-hackernews-ucontent
1033c84bf59a108d896c1064ada77f3c8d75e6ed
[ "WTFPL" ]
1
2021-02-10T09:32:43.000Z
2021-02-10T09:32:43.000Z
app/server.js
imnutz/sam-hackernews-ucontent
1033c84bf59a108d896c1064ada77f3c8d75e6ed
[ "WTFPL" ]
null
null
null
app/server.js
imnutz/sam-hackernews-ucontent
1033c84bf59a108d896c1064ada77f3c8d75e6ed
[ "WTFPL" ]
null
null
null
import path from 'path' import {readFileSync} from 'fs'; import { render } from 'ucontent' import { intents, sam } from './sam.js' import { css } from 'ucontent'; import theme from './theme.js' import express from 'express' const style = css(readFileSync(path.resolve('styles/style.css'))); const app = express() const port = 3000 const middleware = function (req, res, next) { sam.setRender((model) => { const representation = theme(model, style) render(content => res.end(content), representation) }) next() } app.use(middleware) app.get('/', intents.iGetTopStories) app.get('/top', intents.iGetTopStories) app.get('/new', intents.iGetNewStories) app.get('/show', intents.iGetShowStories) app.get('/ask', intents.iGetAskStories) app.get('/jobs', intents.iGetJobStories) app.listen(port, () => { console.log(`Server is running at ${port}`) })
25.470588
66
0.69746
c4c4eaee1a20171282ed357f909df3f6adf70264
8,383
js
JavaScript
js/shape-only/gan1_su4_lin2_xia4_hui2_zu2_zi4_zhi4_zhou1.js
627992512/echarts-china-cities-js
ffd1a1c123db96460d3dc89914f0e7f601233934
[ "MIT" ]
368
2018-02-28T07:39:59.000Z
2022-03-27T14:01:21.000Z
js/shape-only/gan1_su4_lin2_xia4_hui2_zu2_zi4_zhi4_zhou1.js
zbaoxing/echarts-china-cities-js
ffd1a1c123db96460d3dc89914f0e7f601233934
[ "MIT" ]
10
2018-05-17T11:46:00.000Z
2022-03-13T16:22:59.000Z
js/shape-only/gan1_su4_lin2_xia4_hui2_zu2_zi4_zhi4_zhou1.js
zbaoxing/echarts-china-cities-js
ffd1a1c123db96460d3dc89914f0e7f601233934
[ "MIT" ]
216
2018-02-28T07:40:09.000Z
2022-03-23T08:51:36.000Z
(function (root, factory) {if (typeof define === 'function' && define.amd) {define(['exports', 'echarts'], factory);} else if (typeof exports === 'object' && typeof exports.nodeName !== 'string') {factory(exports, require('echarts'));} else {factory({}, root.echarts);}}(this, function (exports, echarts) {var log = function (msg) {if (typeof console !== 'undefined') {console && console.error && console.error(msg);}};if (!echarts) {log('ECharts is not Loaded');return;}if (!echarts.registerMap) {log('ECharts Map is not loaded');return;}echarts.registerMap('临夏回族自治州轮廓', {"type":"FeatureCollection","features":[{"type":"Feature","properties":{"name":"临夏回族自治州"},"geometry":{"type":"Polygon","coordinates":["@@@AD@BAB@@ABABAHAD@B@DAD@@AB@@ABABCBA@AB@FCBAFCDCFCB@BBDBB@BAFEDAB@BABABABA@ABA@ABCBADA@ABA@A@C@CBABCBA@AB@BAH@B@@AB@@CBC@GBABADADAFCBABCBABA@EBA@AB@@C@AB@BAB@DBDBB@BB@BB@BFBBB@@BB@B@BABAB@BA@A@CAC@A@A@ABA@ADADCD@@ADAD@B@B@B@D@B@B@BABA@A@A@AAA@AB@BABA@ABABABABA@ABADABA@A@A@AA@@A@A@A@A@A@AAA@CAA@A@A@A@A@A@AB@BADCBAB@B@D@BBBBBBB@H@B@FCB@DAB@F@B@BAB@BCBCAC@A@C@CBA@ADAFABADAB@DCDAB@BADABC@E@A@C@A@A@C@CDCBCBADAB@HCB@BABABABABA@AB@BCBABABA@ABCDABAB@@AB@@AB@@ABCB@@ABA@AB@DA@AF@B@HCBABCBABADAB@DCBABAB@@AB@B@D@B@BAB@@ABAB@@AB@B@B@@AHABABAB@DCBA@AFAB@B@B@BA@ABA@A@A@ADAB@BAB@@ABA@ABAB@D@BABC@A@AB@@AB@BADABABAB@BCBAB@BABABCB@@ABA@ABABABAB@B@D@D@D@B@BADA@ADC@ADCDA@ABABA@ABA@C@A@ABCB@BA@AB@BABABCBE@EBC@ABCBI@A@A@C@A@C@A@ABABA@AB@@A@AAAA@@A@A@ABAB@BABADC@ABA@A@A@CBABABABABC@AB@BCDABEDEBA@A@ABA@AB@B@B@D@BBBABAB@FABCDE@A@ADEJY@CBA@AFABABA@ABCBCBA@AFAB@B@B@BBBD@B@BB@B@F@HAFA@A@AAAA@CCAAAA@A@AAA@AAA@A@ABA@AA@@A@CBAA@AAA@@A@AB@@AAA@BABA@A@@AA@AAA@CCC@AAA@@A@AAAA@AAAACCACAA@A@A@AAC@AAA@A@C@AAA@ACC@AA@AC@AA@AAA@C@C@A@ABA@C@A@A@AACAA@AA@AAAC@@AAA@A@ABA@A@A@AB@BAB@BADA@AB@@AB@@AB@@ABA@ABABA@CBAB@@A@AAABA@AA@BA@AB@@AEE@G@A@A@A@A@CAAA@A@AAA@A@AA@AA@AB@DABAFA@CAECCCAAA@CAA@A@A@C@A@A@@AA@@AEC@A@C@ABA@AAA@A@C@E@C@AD@@A@AAACC@AAA@A@A@AA@@AAA@CAA@ABC@A@A@AAAAAAAA@AAA@@AA@AAAAA@@AA@AAA@@A@AA@AA@A@AA@@AAA@A@CAAAAA@AAAA@AA@BAAAB@@AA@BABA@CAA@AAACAAC@A@AA@AAAAC@C@A@@BABA@A@A@A@A@AAAA@A@A@A@ADE@A@ACAA@@A@A@A@AAAA@@A@AA@AA@ABA@A@CBAAA@ABA@A@A@A@AAC@AB@@ABAA@@A@A@AAAAAA@AA@AA@A@A@AAAAA@AAA@A@@AAAAAA@@A@A@A@AA@@A@AAAA@AAA@@AAAAA@AAAAA@AAC@AACAA@AAA@A@A@AAAAC@AAAAA@AAA@AAAAAAAA@@A@AA@AA@AAA@AA@@AA@@AA@@A@CACB@BC@ABA@AB@@AB@AAGACAA@AA@AB@BABA@AAABC@AB@D@DAF@F@@ABCBABAB@B@B@BBBBD@B@BBB@BAD@BBBBB@B@F@B@@A@A@A@AA@AAA@@AAAA@@AA@AAA@AAAA@ABC@A@ABCBA@ABC@A@AB@DCBEB@AAAAAA@ABA@A@A@A@AB@@A@AA@A@AA@A@AAAA@CCA@@A@A@A@ABAB@@A@A@CBC@C@AB@@A@CACBCAABADCB@BA@A@AB@BBBB@BBB@BBBDBBBB@B@BCB@BADADAB@BAB@BA@ABAB@H@@A@AA@@AB@@CBCBA@AA@AAA@AAC@CAAAAA@ABA@CAA@ACA@A@AB@BAB@FEDCDABADC@AC@AAA@@AAAA@@A@A@ADABCBA@A@AA@AAAA@AAACCA@AAAA@C@A@CBABABABABAFA@A@A@AAAACAAAA@A@C@ABADBB@B@@ABA@A@AAC@A@ABABABADA@AFAB@B@@E@AB@@AB@B@H@D@BABABABABABABADADAHAD@BADABA@AAA@AAA@A@A@C@I@ADA@AFEB@B@JCB@BB@BA@@BB@@BB@BCDEDCB@B@DADBB@BBB@BBF@@ABABAFCB@BA@ABAB@D@BAB@HGBA@A@ABA@ABA@ADCBCBADAB@@AAA@A@C@ABAB@@AB@BA@ABC@ABA@A@E@A@AA@@A@AAE@C@AAAAAAACAA@AAAAAC@EAIA@@EAE@AAA@A@A@ABABABABABA@ADE@ABCBAA@ABGBABA@C@EDAB@B@JAD@BEH@BCBGBKDA@E@A@A@ABADABA@E@E@C@CBC@C@A@GCA@A@C@C@KAAAG@A@C@OBC@C@ECCAICCAC@AAEBC@A@I@EAEAC@CAEAA@C@AAA@E@C@C@@AA@AAAAECA@GCC@GAAAA@EDA@EDCBCBABAFABAB@DBBBB@BBD@BABABCDAD@BBB@BFDJHLL@BBB@B@DBBB@BBF@B@B@FBFBBAB@BBB@B@DBB@BBB@B@BBBBBABBB@@FBBBBB@@BBB@BAB@BBBDBBBF@B@AAB@DEB@LR@B@B@B@BABAB@FAD@F@H@B@BBDBB@BAB@BA@@BA@C@A@A@CAC@CAA@AACA@A@AA@@AE@C@C@AAIECAAC@AA@AAAAA@CAA@ABEDCBEBA@C@A@AB@D@B@BB@F@B@BABBDBB@DDDBJHB@B@DDFBB@DBB@D@B@H@FAD@D@B@J@BBB@@BBB@BA@CHABA@A@C@CB@BKJAB@B@BABADADAB@B@H@BABABABA@ABA@C@CAGCACAAA@A@ABABA@AAA@G@A@A@A@@B@DADABABAB@DABBB@BBFABABABCDEDA@GDA@C@CBA@CBA@@BCBABABAF@BABIDABCDA@EBEDABCBC@CBCBAB@DGL@D@BABCBMJABA@A@QBA@C@EBIDEDGDA@EBEDEDGDOJABA@ABIFABCBABEBA@CBCDGHA@A@A@A@KHEBA@CBABC@C@A@OFKDABA@@A@AA@@AA@@BA@AB@AAACAEA@ACGAG@CBC@C@EAA@A@AA@C@C@C@CBIACBC@CBGBABGBEDGBGDEDC@@BMAG@A@A@CBA@A@A@CBC@C@CBIFC@ABCAECEAA@C@A@CBABC@A@C@EAA@EBC@A@ABA@A@AA@AA@@AC@CBGBC@A@CBC@A@ABCBEDCHEAA@ABIHEDA@EBABCBCBEBEB@BABBDA@IFCDCBA@AB@B@BA@M@C@A@EFEFA@CDEBGDA@E@A@IBC@CBABA@AAG@I@U@MBWHUDE@K@O@GBMAABEBK@G@ABKDC@ABCBAD@BABADADCDEDIFIFEFKHCB@BK@GBEBC@ABAB@BA@ABA@A@CAABAAC@A@ABA@A@ABA@CBAH@B@FA@ABE@C@C@C@A@@AABAB@H@BCH@BAD@B@B@BBB@B@BADA@ABAF@B@BBD@BAAE@E@A@CAC@CAC@ABA@A@A@A@C@A@A@A@A@AAA@A@A@A@A@A@AAA@ABA@ABA@A@A@ABABCBADAD@BAB@BC@A@A@AA@AA@A@A@ABA@ABA@A@AAEAABA@A@GBA@ABA@A@A@A@ADE@ABA@ABC@CDA@@A@AAAAAIEAAAA@AAA@C@C@A@A@C@AAAEEEE@C@C@AA@@AC@A@CEEC@AABCDEBABCFA@A@A@A@@BCBCBAB@JAB@BCF@BAJAF@B@BAF@D@BBBBBBD@BBBB@@BABED@BAD@B@BBBBBHJBDBFBBEDABCJBBBD@B@D@B@BBB@BBDBB@BAB@D@D@BBB@B@B@BAB@B@BBDDDBB@BBD@B@DAB@F@BABABAB@B@B@B@DBD@HDF@B@B@DAD@BADED@BAFCB@F@B@B@BCDADABCBEBA@A@ABCDCD@BABAFADABE@A@ABA@CBADA@A@C@E@ABABC@A@A@A@@AAAAAAAA@AACC@AA@@AAACCAACAAAA@A@AAGMAAA@A@@BC@CBCBA@A@EBEB@BA@ABCBE@AAAB@B@BCB@B@DABADGDABABIBA@@D@BBBBB@DA@@B@BABA@ABEAABABABE@CBA@@DADAF@D@BABCDADCFEHADA@A@C@ABC@@BCAC@CBG@GBEBCBA@E@C@A@AAEBGDG@EBABA@AD@BA@AAA@A@A@A@A@@BADABEBABA@EBEBCBABCFADADADABB@B@JHFFBBBFBB@B@B@BDBBBB@BBB@B@BBBB@BB@@BB@@BB@DDFBB@B@B@B@BB@B@DBBB@BBBBBB@B@BAB@B@B@BA@A@@B@BA@A@A@A@A@AAmIGACGAAAACAA@C@C@GBC@CB@B@B@DABAD@BDDB@LFB@JFDHDBBBFBF@B@R@VHH@F@DADBDDJLDBD@D@LCF@FBBDCPKNQLYNKNEF@B@DADBB@B@DA@ADKH@D@BFD@BADCBAFDFFRDJAH@HAHEDMBIBA@GBGBCDCHCD@DAFCBCHK`GFMHONKRAFABCLAR@D@BAJ@JAF@BCDM\\@BANDHNHBFCRBJRDDDJHDBBLBDBFFBB@D@D@BBB@DBDDD@H@D@B@D@BBBDBDBBBDBBFDFDB@B@@BB@@DBB@BDBBBB@B@BBB@@BDBFHBBDBBBBB@JB@BBBBHDDBFDD@B@DAHCFABADAF@DAD@DAD@DAB@FCDA@AB@B@B@DBDDBBBBDBDBH@D@F@F@BAF@FABABAB@@A@C@AB@@ABAB@BABBB@D@B@BBDAD@B@B@FAD@B@@AD@BBDBDBDBD@F@B@D@LEHAB@DAF@F@HBB@D@DCBEDADGBCBAB@B@B@B@BBB@DBD@B@D@BABABADADAB@B@BBBBBB@BBB@BB@B@@BAHAB@B@B@BAD@BBD@B@B@BBBBBB@@BBB@BBBB@@BBB@BBB@BADAB@DABABAB@BAD@BA@BDAB@D@DA@@B@BAB@B@D@B@B@BBB@DBB@BBB@BA@@BAD@B@B@B@B@BBBBBAB@B@DA@AB@D@DBB@D@DABCDABCDAB@BBD@BBF@DBD@D@D@D@DBDBBDDBBBD@D@B@B@DAB@B@DBD@BDDBBDDBDBDBBBDDFFDBBBBBD@BBBBDBBBBBFC@A@ABABAD@B@DAD@BABADABA@ABC@EFABADAB@DAF@BBBBDDBDDBBDDBDBBB@BBB@B@DAB@B@BAB@BBB@B@@BB@@BA@@BA@AB@BCB@BA@@DA@@BA@A@K@EBC@A@A@A@EBABA@A@@BADABA@A@KCGAA@A@@BABABABAB@DABADABAB@BA@A@A@A@@BAB@BAB@BA@C@E@A@A@@B@DAB@BA@A@E@AA@AAA@CA@E@C@A@A@@B@D@B@B@BA@@B@BA@@BBB@BABC@A@C@A@A@A@@BABCD@B@B@BBB@D@BBBBBB@BBB@B@B@BBB@B@B@B@B@BADABADAF@BAD@BBB@DBBBD@@BDFBBDBFBFBD@DBBBBBB@B@B@B@B@@BBBB@B@BBBB@BBB@D@B@FBBBFBF@BBDBH@D@DAB@B@BBBB@BBB@BBDDBB@DABCFADAD@B@BBBB@B@BAB@F@D@B@B@BBB@B@B@B@B@DF@DBB@BBB@DADBB@BBB@DBBB@BBD@B@@BB@@D@B@BBBFFDD@BA@@BA@@B@B@BB@BBD@BBBB@B@BAB@BBBD@B@D@F@B@B@B@B@B@BBBBDBBDDDBBBBF@FBB@FBB@DAF@BAB@DAF@F@FABAB@FBDAFADBB@DBFBDBF@H@B@D@BBBB@BB@BBB@B@F@D@DBFDB@BBD@B@B@BAB@D@BAB@B@B@BBD@DDB@B@@BBH@BBDBBBBB@@BB@BAB@DCBABABE@A@EAA@A@A@ADAB@DAB@BABA@A@A@A@A@A@ABA@AB@D@F@D@BBB@B@@BB@B@B@DCBABABA@ABA@ABAB@B@B@D@B@D@BBDBB@B@B@@AB@BABAB@BCB@@CBA@A@A@A@A@ABAB@@AD@B@DADBD@B@B@BBFDB@D@H@DDB@B@B@DABABABABABA@A@ABABA@AB@BAB@BAB@B@B@@DB@@BB@HADAB@J@D@B@H@B@B@@A@A@A@C@C@AB@@AB@F@D@B@B@BADABAB@B@B@B@FBBBB@BBB@B@B@B@BABABA@ABEAA@C@AAA@AB@@AD@F@D@DBB@B@BBBBDBBBB@BBD@BABAFAD@B@D@FCB@BAB@B@@AB@B@DBBBBBDBDBD@BDB@BBBAB@FABABABABABI@A@A@CBAB@D@@BDBD@D@B@D@FABABCBABCBABEBC@CBAB@BAF@D@B@D@HBHAFABAD@B@B@BBD@BBD@HBD@HAFBDBDBDDDBB@B@B@@A@AB@B@BAB@BBB@D@D@BABABABA@ABABAAA@ABA@A@A@CA@BAA@@A@AAA@A@AA@@A@AAAAB@AAABA@ABA@A@C@C@A@AAAAA@CA@@AA@@A@AB@DA@A@A@ABA@AAA@ABAB@BAB@B@B@BAB@BAB@@A@A@AD@B@DAB@B@D@B@B@B@B@B@@BBAD@BABAB@B@BDB@BBBBDBBDB@@BBBBBDBB@@BBB@B@BD@BBBBB@DH@DBB@F@F@F@B@DBB@BBBBBB@BBFBBBB@D@BBB@@ADEBE@AB@BAAAB@B@@ABA@AB@@AD@BBB@B@B@B@BAB@B@FD@BAB@BAB@B@BBB@BB@@BDADADA@AB@BADAB@D@B@B@B@B@@BB@BAD@B@B@@AF@B@B@B@DBD@B@B@DBB@B@B@DBD@B@BABADABAFCHAB@DAB@BAFAHCB@BAB@D@B@B@B@BAAI@AB@@A@AB@@ADAB@@AAEBGBC@CAEAA@CBA@AB@@BB@DBFDB@HBB@B@DBDBB@F@DABADCBC@ABC@CB@BABA@ADC@A@C@A@A@ABA@AB@@CB@B@@ABC@CBA@ADAFE@CBC@ABA@ABAB@B@@CB@BAB@B@BADABA@ABA@C@ACAAA@ACE@AA@A@A@CA@A@I@AAAAAAA@AB@BA@AB@B@@A@AB@@ACC@ABAB@B@DBBABAFC@AB@@A@AAAACICAA@AAEA@@ACACA@AAAAA@A@A@CAA@ABABC@A@E@A@C@C@AB@BA@ABCB@@A@G@CAA@AC@C@A@A@A@C@A@AAAAAAAA@A@A@AB@@A@AAE@A@ABA@A@AA@@AA@AAAAA@@AA@A@@A@AAA@AC@C@A@AAC@A@AAA@AAAAA@A@@AAB@AA@ABAA@AA@A@A@A@AAC@A@@BA@ABA@A@GBA@C@C@A@A@AB@DAFAFAD@BAD@B@BABA@@B@BAB@B@B@BBF@B@BA@@BC@ABCBC@AAA@A@A@ABA@A@ABA@A@@B@B@BAB@BA@A@A@ABA@A@@BA@A@A@A@@BA@@BA@@AA@ABA@A@A@A@A@CAA@@AA@@AAAA@AA@AAA@A@A@A@AA@ACAAAAAAAAA@@AA@AAA@@AA@@AAAAAA@@AA@@AA@@AA@AAAA@AA@A@@A@AA@A@A@@A@C@AA@ABABABABAD@BCBA@A@A@ACA@AA@ABAAA@ABA@A@AAA@AB@@A@ABA@AAC@AAAB@@A@AB@@A@CDA@A@A@A@A@AA@@AAAAAAA@A@A@A@A@AA@AAA@"],"encodeOffsets":[[105953,36741]]}}],"UTF8Encoding":true});}));
8,383
8,383
0.717166
c4c527d9d0b1ae8ba5c343a074f1c56cddc11ad8
119
js
JavaScript
__mocks__/lodash-webpack-plugin.js
104corp/espack
232146815bad932b1b6246c391238189db6b1864
[ "MIT" ]
10
2018-09-10T14:56:59.000Z
2020-12-01T05:15:16.000Z
__mocks__/lodash-webpack-plugin.js
104corp/espack
232146815bad932b1b6246c391238189db6b1864
[ "MIT" ]
1
2020-09-04T04:50:42.000Z
2020-09-04T04:50:42.000Z
__mocks__/lodash-webpack-plugin.js
104corp/espack
232146815bad932b1b6246c391238189db6b1864
[ "MIT" ]
1
2018-12-17T06:39:44.000Z
2018-12-17T06:39:44.000Z
class LodashWebpackPlugin { constructor(options) { return options; } } module.exports = LodashWebpackPlugin;
13.222222
37
0.731092
c4c5477d6a3db8e2f400b810303980a41c70c2e4
991
js
JavaScript
webpack.config.js
samueldobbie/remarkable
2eb73c16ace781fa1f3efec0284cfcd1620e4de3
[ "MIT" ]
116
2022-01-31T00:48:50.000Z
2022-03-30T03:40:12.000Z
webpack.config.js
samueldobbie/remarkable
2eb73c16ace781fa1f3efec0284cfcd1620e4de3
[ "MIT" ]
3
2022-02-22T21:09:14.000Z
2022-02-27T13:58:26.000Z
webpack.config.js
samueldobbie/remarkable
2eb73c16ace781fa1f3efec0284cfcd1620e4de3
[ "MIT" ]
2
2022-02-07T05:02:00.000Z
2022-02-22T22:45:28.000Z
const { resolve } = require("path") const { CleanWebpackPlugin } = require("clean-webpack-plugin") const HTMLWebpackPlugin = require("html-webpack-plugin") const CopyWebpackPlugin = require("copy-webpack-plugin") module.exports = { mode: "development", devtool: "cheap-module-source-map", entry: { background: "./src/background/Background.ts", popup: "./src/popup/Popup.tsx", }, output: { filename: "[name].js", path: resolve(__dirname, "build"), }, resolve: { extensions: [ ".js", ".jsx", ".ts", ".tsx", ], }, module: { rules: [{ test: /\.ts(x?)$/, exclude: /node_modules/, use: "ts-loader", }], }, plugins: [ new HTMLWebpackPlugin({ template: "src/popup/templates/popup.html", filename: "popup.html", chunks: ["popup"], }), new CopyWebpackPlugin({ patterns: [{ from: "public", to: ".", }], }), new CleanWebpackPlugin(), ] }
21.085106
62
0.553986
c4c66ab48753b77b7bcf2b0ad1766d20bab02235
2,102
js
JavaScript
jobfeed/src/addscomponents/CompanyProfile/Video.js
nikhilgupta2001/Forever_Knights
fbc1467465082d19974be42e290a2565043a51bf
[ "MIT" ]
3
2021-04-07T18:42:29.000Z
2021-12-28T17:27:41.000Z
jobfeed/src/addscomponents/CompanyProfile/Video.js
mrSidSat/Forever_Knights
dc3b5b7504e03abbf49e2b89799d52756df77b43
[ "MIT" ]
null
null
null
jobfeed/src/addscomponents/CompanyProfile/Video.js
mrSidSat/Forever_Knights
dc3b5b7504e03abbf49e2b89799d52756df77b43
[ "MIT" ]
7
2021-04-07T18:08:51.000Z
2021-10-18T10:43:40.000Z
import React from 'react'; import Piechart from './Piechart'; const Video = (props) => { console.log(props); return ( <div className="conatiner"> <div className="row shadow-lg p-4 " style={{ backgroundColor: "#ffffff",height:""}} > <div className="col-md-4"> <video style={{ width: "100%" }} height="" id="my-video" class="video-js" controls preload="auto" // width="100% // height="200px" poster={props.props.thumbnailurl} data-setup=" " > <source src={props.props.videoUrl} type="video/mp4" /> <source src="MY_VIDEO.webm" type="video/webm" /> <p class="vjs-no-js"> To view this video please enable JavaScript, and consider upgrading to a web browser that <a href="https://videojs.com/html5-video-support/" target="_blank" >supports HTML5 video</a > </p> </video> </div> <div className="col-md-3 col-sm-12 text-center shadow-sm border p-2" style={{fontStyle:"italic",borderRadius:"10%"}}> {props.props.writeup} {/* standard dummy text ever since the 1500s, when an unknown printer took a galley of type and scrambled it to make a type specimen book. It has survived not only five centuries, */} </div> <div className="col-md-5 col-sm-12 shadow-sm border" style={{fontStyle:"italic",borderRadius:"10%"}}> {/* <canvas className="canvas"></canvas> {appendchart} </div> */} <Piechart views={props.props.views} req={props.props.requiredviews} /> </div> </div> </div> ) }; {/* estimated={url.estimated} */} export default Video;
41.215686
130
0.47431
c4c6ac612af3b49619969fc0a3f7b5082a5a6d1c
8,783
js
JavaScript
public/js/user/radiology_type/radiologyTypeCreateCtrl.js
syaifuddinh/medicelle
ef0b27b7b650584c81bec9f6de3b6729d1071303
[ "MIT" ]
null
null
null
public/js/user/radiology_type/radiologyTypeCreateCtrl.js
syaifuddinh/medicelle
ef0b27b7b650584c81bec9f6de3b6729d1071303
[ "MIT" ]
null
null
null
public/js/user/radiology_type/radiologyTypeCreateCtrl.js
syaifuddinh/medicelle
ef0b27b7b650584c81bec9f6de3b6729d1071303
[ "MIT" ]
null
null
null
app.controller('radiologyTypeCreate', ['$scope', '$http', '$rootScope', '$compile', '$timeout', '$filter', function($scope, $http, $rootScope, $compile, $timeout, $filter) { $scope.title = 'Tambah Jenis Pemeriksaan Radiologi'; $scope.data = {} $scope.formData = { price : {}, detail : [] } var path = window.location.pathname; $scope.countGrandtotal = function() { var price_text = $('.price-text') var grandtotal = 0; if(price_text.length > 0) { for(p = 0;p < price_text.length;p++) { grandtotal += parseInt($(price_text[p]).val() || 0) } } grandtotal = $filter('number')(grandtotal) $('#grandtotal').text(grandtotal) } if(/edit/.test(path)) { $scope.title = 'Edit Jenis Pemeriksaan Radiologi'; id = path.replace(/.+\/(\d+)/, '$1'); $http.get(baseUrl + '/controller/user/radiology_type/' + id).then(function(data) { $scope.is_init = 1 $scope.formData = data.data $scope.formData.price.price = data.data.price.custom_price $scope.formData.price.service_price = data.data.price.service.service_price $scope.formData.price.piece_id = data.data.price.service.piece_id var detail = data.data.radiology_type_detail var unit $scope.formData.detail = [] for(x in detail) { unit = detail[x] detail[x].item_name = unit.name $scope.insertItem(unit) } $scope.is_init = 0 }, function(error) { $rootScope.disBtn=false; if (error.status==422) { var det=""; angular.forEach(error.data.errors,function(val,i) { det+="- "+val+"<br>"; }); toastr.warning(det,error.data.message); } else { toastr.error(error.data.message,"Error Has Found !"); } }); } $scope.insertItem = function(data = {}) { $scope.formData.detail.push(data) radiology_type_detail_datatable.row.add(data).draw() if($scope.is_init != 1) { $timeout(function () { $scope.showItemModal($scope.formData.detail.length - 1) }, 400) } } $scope.selectItem = function(obj) { var tr = $(obj).parents('tr') var data = item_datatable.row(tr).data() $scope.formData.detail[$scope.currentIndex].item_name= data.name $scope.formData.detail[$scope.currentIndex].item_id= data.id $('#itemModal').modal('hide') } $scope.showItemModal = function(index) { item_datatable.ajax.reload() $scope.currentIndex = index $('#itemModal').modal() } $scope.deleteDetail = function(obj) { var row = $(obj).parents('tr') radiology_type_detail_datatable.row(row).remove().draw() $scope.countGrandtotal() } $scope.addDetail = function() { radiology_type_detail_datatable.row.add({}).draw() } changeName = function(obj) { var name = $(obj).val() var row = $(obj).parents('tr') var data = radiology_type_detail_datatable.row(row).data() data['name'] = name radiology_type_detail_datatable.row(row).data(data).draw() } changePrice = function(obj) { var price = $(obj).val() var row = $(obj).parents('tr') var data = radiology_type_detail_datatable.row(row).data() data['price'] = price radiology_type_detail_datatable.row(row).data(data).draw() $(obj).val(price) $scope.countGrandtotal() } radiology_type_detail_datatable = $('#radiology_type_detail_datatable').DataTable({ dom: 'rt', pageLength: 200, columns:[ { data: null, orderable : false, searchable : false, render : function(resp) { var index = $scope.formData.detail.length - 1 return "<div style='height:9mm' ng-click='showItemModal(" + index + ")'><% formData.detail[" + index + "].item_name %></div>" } }, { data: null, orderable : false, searchable : false, render : function(resp) { var index = $scope.formData.detail.length - 1 return "<input type='text' class='form-control' ng-model='formData.detail[" + index + "].qty' style='width:16mm' jnumber2 only-num>" } }, { data: null, orderable : false, searchable : false, width : '15mm', className : 'text-center', render :function(resp) { var index = $scope.formData.detail.length - 1 return "<button class='btn btn-xs btn-danger' ng-click='deleteDetail($event.currentTarget)' title='Hapus'><i class='fa fa-trash-o'></i></button>" } }, ], createdRow: function(row, data, dataIndex) { $compile(angular.element(row).contents())($scope); $(row).find('input').focus() } }); item_datatable = $('#item_datatable').DataTable({ processing: true, serverSide: true, ajax: { url : baseUrl+'/datatable/master/medical_item', data : function(d) { d.length = 6 d.is_active = 1 return d } }, columns:[ { data:null, name:null, searchable:false, orderable:false, className : 'text-center', render : resp => "<button ng-disabled='disBtn' type='button' class='btn btn-xs btn-primary' ng-click='selectItem($event.currentTarget)'>Pilih</button>" }, {data:"unique_code", orderable:false,searchable:false}, {data:"name", name:"name"}, ], createdRow: function(row, data, dataIndex) { $compile(angular.element(row).contents())($scope); } }); changeName = function(obj) { var name = $(obj).val() var input = { 'name' : name } var row = $(obj).parents('tr') radiology_type_detail_datatable.row(row).data(input).draw() } $scope.grup_nota = function() { $http.get(baseUrl + '/controller/user/grup_nota').then(function(data) { $scope.data.grup_nota = data.data }, function(error) { $rootScope.disBtn=false; if (error.status==422) { var det=""; angular.forEach(error.data.errors,function(val,i) { det+="- "+val+"<br>"; }); toastr.warning(det,error.data.message); } else { $scope.grup_nota() toastr.error(error.data.message,"Error Has Found !"); } }); } $scope.grup_nota() $scope.piece = function() { $http.get(baseUrl + '/controller/master/piece/actived').then(function(data) { $scope.data.piece = data.data }, function(error) { $rootScope.disBtn=false; if (error.status==422) { var det=""; angular.forEach(error.data.errors,function(val,i) { det+="- "+val+"<br>"; }); toastr.warning(det,error.data.message); } else { $scope.piece() toastr.error(error.data.message,"Error Has Found !"); } }); } $scope.piece() $scope.reset = function() { $scope.formData = {} radiology_type_detail_datatable.clear().draw() } $scope.deleteDetail = function(obj) { var row = $(obj).parents('tr') radiology_type_detail_datatable.row(row).remove().draw() } $scope.addDetail = function() { radiology_type_detail_datatable.row.add({}).draw() } $scope.submitForm=function() { $rootScope.disBtn=true; var url = baseUrl + '/controller/user/radiology_type'; var method = 'post'; if($scope.formData.id) { var url = baseUrl + '/controller/user/radiology_type/' + id; var method = 'put'; } $http[method](url, $scope.formData).then(function(data) { $rootScope.disBtn = false toastr.success("Data Berhasil Disimpan !"); setTimeout(function () { window.location = baseUrl + '/radiology_type' }, 1000) }, function(error) { $rootScope.disBtn=false; if (error.status==422) { var det=""; angular.forEach(error.data.errors,function(val,i) { det+="- "+val+"<br>"; }); toastr.warning(det,error.data.message); } else { toastr.error(error.data.message,"Error Has Found !"); } }); } }]);
33.143396
173
0.537743
c4c6af80e3089574e64f28615340ed5705024ace
654
js
JavaScript
src/api/user.js
WeiweiQi/hold-vue-element-template
9a89e3ac5b7ca448dbb3ebd7df0c3c3a0c444e68
[ "MIT" ]
null
null
null
src/api/user.js
WeiweiQi/hold-vue-element-template
9a89e3ac5b7ca448dbb3ebd7df0c3c3a0c444e68
[ "MIT" ]
null
null
null
src/api/user.js
WeiweiQi/hold-vue-element-template
9a89e3ac5b7ca448dbb3ebd7df0c3c3a0c444e68
[ "MIT" ]
null
null
null
import request from '@/utils/request' export function login(data) { console.log('user/login...') console.log('data:' + data.username) return request({ url: '/vuelogin/mylogin', method: 'post', params: { username: data.username, password: data.password }, data }) } export function mylogin(data) { return request({ url: '/vuelogin/mylogin', method: 'post', data }) } export function getInfo(token) { return request({ url: '/vuelogin/info', method: 'get', params: { token } }) } export function logout() { return request({ url: '/vuelogin/logout', method: 'post' }) }
16.769231
38
0.599388