silverstripe-framework/admin/client/dist/js/bundle-framework.js

6 lines
106 KiB
JavaScript
Raw Normal View History

Merge 3 into master # Conflicts: # admin/javascript/LeftAndMain.Tree.js # admin/javascript/lang/cs.js # admin/javascript/lang/de.js # admin/javascript/lang/en.js # admin/javascript/lang/eo.js # admin/javascript/lang/es.js # admin/javascript/lang/fa_IR.js # admin/javascript/lang/fi.js # admin/javascript/lang/fr.js # admin/javascript/lang/id.js # admin/javascript/lang/id_ID.js # admin/javascript/lang/it.js # admin/javascript/lang/ja.js # admin/javascript/lang/lt.js # admin/javascript/lang/mi.js # admin/javascript/lang/nb.js # admin/javascript/lang/nl.js # admin/javascript/lang/pl.js # admin/javascript/lang/ro.js # admin/javascript/lang/ru.js # admin/javascript/lang/sk.js # admin/javascript/lang/sl.js # admin/javascript/lang/sr.js # admin/javascript/lang/sr@latin.js # admin/javascript/lang/sr_RS.js # admin/javascript/lang/sr_RS@latin.js # admin/javascript/lang/src/cs.js # admin/javascript/lang/src/de.js # admin/javascript/lang/src/en.js # admin/javascript/lang/src/eo.js # admin/javascript/lang/src/es.js # admin/javascript/lang/src/fi.js # admin/javascript/lang/src/fr.js # admin/javascript/lang/src/id.js # admin/javascript/lang/src/id_ID.js # admin/javascript/lang/src/it.js # admin/javascript/lang/src/ja.js # admin/javascript/lang/src/lt.js # admin/javascript/lang/src/mi.js # admin/javascript/lang/src/nb.js # admin/javascript/lang/src/nl.js # admin/javascript/lang/src/pl.js # admin/javascript/lang/src/ro.js # admin/javascript/lang/src/ru.js # admin/javascript/lang/src/sk.js # admin/javascript/lang/src/sl.js # admin/javascript/lang/src/sr.js # admin/javascript/lang/src/sr@latin.js # admin/javascript/lang/src/sr_RS.js # admin/javascript/lang/src/sr_RS@latin.js # admin/javascript/lang/src/sv.js # admin/javascript/lang/src/zh.js # admin/javascript/lang/sv.js # admin/javascript/lang/zh.js # css/GridField.css # forms/gridfield/GridFieldExportButton.php # javascript/GridField.js # javascript/lang/ar.js # javascript/lang/cs.js # javascript/lang/de.js # javascript/lang/en.js # javascript/lang/en_GB.js # javascript/lang/eo.js # javascript/lang/es.js # javascript/lang/fi.js # javascript/lang/fr.js # javascript/lang/id.js # javascript/lang/id_ID.js # javascript/lang/it.js # javascript/lang/ja.js # javascript/lang/lt.js # javascript/lang/mi.js # javascript/lang/nb.js # javascript/lang/nl.js # javascript/lang/pl.js # javascript/lang/ru.js # javascript/lang/sk.js # javascript/lang/sl.js # javascript/lang/sr.js # javascript/lang/sr@latin.js # javascript/lang/sr_RS.js # javascript/lang/sr_RS@latin.js # javascript/lang/src/ar.js # javascript/lang/src/cs.js # javascript/lang/src/de.js # javascript/lang/src/en.js # javascript/lang/src/eo.js # javascript/lang/src/es.js # javascript/lang/src/fi.js # javascript/lang/src/fr.js # javascript/lang/src/id.js # javascript/lang/src/id_ID.js # javascript/lang/src/it.js # javascript/lang/src/ja.js # javascript/lang/src/lt.js # javascript/lang/src/mi.js # javascript/lang/src/nb.js # javascript/lang/src/nl.js # javascript/lang/src/pl.js # javascript/lang/src/ru.js # javascript/lang/src/sk.js # javascript/lang/src/sl.js # javascript/lang/src/sr.js # javascript/lang/src/sr@latin.js # javascript/lang/src/sr_RS.js # javascript/lang/src/sr_RS@latin.js # javascript/lang/src/sv.js # javascript/lang/src/zh.js # javascript/lang/sv.js # javascript/lang/zh.js # scss/GridField.scss # tests/model/ManyManyListTest.php # tests/model/SQLQueryTest.php
2016-05-11 05:19:35 +02:00
!function e(t,n,r){function s(o,u){if(!n[o]){if(!t[o]){var a="function"==typeof require&&require;if(!u&&a)return a(o,!0);if(i)return i(o,!0);var f=new Error("Cannot find module '"+o+"'");throw f.code="MODULE_NOT_FOUND",f}var l=n[o]={exports:{}};t[o][0].call(l.exports,function(e){var n=t[o][1][e];return s(n?n:e)},l,l.exports,e,t,n,r)}return n[o].exports}for(var i="function"==typeof require&&require,o=0;o<r.length;o++)s(r[o]);return s}({1:[function(require,module,exports){"use strict";function _interopRequireWildcard(obj){if(obj&&obj.__esModule)return obj;var newObj={};if(null!=obj)for(var key in obj)Object.prototype.hasOwnProperty.call(obj,key)&&(newObj[key]=obj[key]);return newObj["default"]=obj,newObj}function _interopRequireDefault(obj){return obj&&obj.__esModule?obj:{"default":obj}}function appBoot(){_ReducerRegister2["default"].add("config",_ConfigReducer2["default"]),_ReducerRegister2["default"].add("form",_FormReducer2["default"]),_ReducerRegister2["default"].add("schemas",_SchemaReducer2["default"]),_ReducerRegister2["default"].add("records",_RecordsReducer2["default"]),_ReducerRegister2["default"].add("campaign",_CampaignReducer2["default"]),_ReducerRegister2["default"].add("breadcrumbs",_BreadcrumbsReducer2["default"]);var initialState={},rootReducer=(0,_redux.combineReducers)(_ReducerRegister2["default"].getAll()),middleware=[_reduxThunk2["default"]];"dev"===window.ss.config.environment&&middleware.push((0,_reduxLogger2["default"])());var createStoreWithMiddleware=_redux.applyMiddleware.apply(void 0,middleware)(_redux.createStore);window.store=createStoreWithMiddleware(rootReducer,initialState),window.store.dispatch(configActions.setConfig(window.ss.config))}var _jQuery=require("jQuery"),_jQuery2=_interopRequireDefault(_jQuery),_redux=require("redux"),_reduxThunk=require("redux-thunk"),_reduxThunk2=_interopRequireDefault(_reduxThunk),_reduxLogger=require("redux-logger"),_reduxLogger2=_interopRequireDefault(_reduxLogger),_ReducerRegister=require("lib/ReducerRegister"),_ReducerRegister2=_interopRequireDefault(_ReducerRegister),_ConfigActions=require("state/config/ConfigActions"),configActions=_interopRequireWildcard(_ConfigActions),_ConfigReducer=require("state/config/ConfigReducer"),_ConfigReducer2=_interopRequireDefault(_ConfigReducer),_FormReducer=require("state/form/FormReducer"),_FormReducer2=_interopRequireDefault(_FormReducer),_SchemaReducer=require("state/schema/SchemaReducer"),_SchemaReducer2=_interopRequireDefault(_SchemaReducer),_RecordsReducer=require("state/records/RecordsReducer"),_RecordsReducer2=_interopRequireDefault(_RecordsReducer),_CampaignReducer=require("state/campaign/CampaignReducer"),_CampaignReducer2=_interopRequireDefault(_CampaignReducer),_BreadcrumbsReducer=require("state/breadcrumbs/BreadcrumbsReducer"),_BreadcrumbsReducer2=_interopRequireDefault(_BreadcrumbsReducer),_index=require("containers/CampaignAdmin/index");_interopRequireDefault(_index);(0,_jQuery2["default"])("body").entwine({onadd:function(){return appBoot()}})},{"containers/CampaignAdmin/index":10,jQuery:"jQuery","lib/ReducerRegister":"lib/ReducerRegister",redux:"redux","redux-logger":36,"redux-thunk":"redux-thunk","state/breadcrumbs/BreadcrumbsReducer":14,"state/campaign/CampaignReducer":17,"state/config/ConfigActions":19,"state/config/ConfigReducer":20,"state/form/FormReducer":22,"state/records/RecordsReducer":25,"state/schema/SchemaReducer":27}],2:[function(require,module,exports){"use strict";function _interopRequireDefault(obj){return obj&&obj.__esModule?obj:{"default":obj}}function _defaults(obj,defaults){for(var keys=Object.getOwnPropertyNames(defaults),i=0;i<keys.length;i++){var key=keys[i],value=Object.getOwnPropertyDescriptor(defaults,key);value&&value.configurable&&void 0===obj[key]&&Object.defineProperty(obj,key,value)}return obj}function _classCallCheck(instance,Constructor){if(!(instance instanceof Constructor))throw new TypeError("Cannot call a class as a function")}function _possibleConstructorReturn(self,call){if(!self)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");
className:"list-group-item-heading"},item.Title),_react2["default"].createElement("span",{className:"list-group-item__info campaign-admin__item-links--is-linked font-icon-link"}),links,badge.className&&badge.Title&&_react2["default"].createElement("span",{className:badge.className},badge.Title))},CampaignAdminItem}(_SilverStripeComponent2["default"]);CampaignAdminItem.propTypes={campaign:_react2["default"].PropTypes.object.isRequired,item:_react2["default"].PropTypes.object.isRequired},exports["default"]=CampaignAdminItem},{i18n:"i18n","lib/SilverStripeComponent":"lib/SilverStripeComponent",react:"react"}],9:[function(require,module,exports){"use strict";function _interopRequireWildcard(obj){if(obj&&obj.__esModule)return obj;var newObj={};if(null!=obj)for(var key in obj)Object.prototype.hasOwnProperty.call(obj,key)&&(newObj[key]=obj[key]);return newObj["default"]=obj,newObj}function _interopRequireDefault(obj){return obj&&obj.__esModule?obj:{"default":obj}}function _defaults(obj,defaults){for(var keys=Object.getOwnPropertyNames(defaults),i=0;i<keys.length;i++){var key=keys[i],value=Object.getOwnPropertyDescriptor(defaults,key);value&&value.configurable&&void 0===obj[key]&&Object.defineProperty(obj,key,value)}return obj}function _classCallCheck(instance,Constructor){if(!(instance instanceof Constructor))throw new TypeError("Cannot call a class as a function")}function _possibleConstructorReturn(self,call){if(!self)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!call||"object"!=typeof call&&"function"!=typeof call?self:call}function _inherits(subClass,superClass){if("function"!=typeof superClass&&null!==superClass)throw new TypeError("Super expression must either be null or a function, not "+typeof superClass);subClass.prototype=Object.create(superClass&&superClass.prototype,{constructor:{value:subClass,enumerable:!1,writable:!0,configurable:!0}}),superClass&&(Object.setPrototypeOf?Object.setPrototypeOf(subClass,superClass):_defaults(subClass,superClass))}function mapStateToProps(state,ownProps){var record=null;return state.records&&state.records.ChangeSet&&ownProps.campaignId&&(record=state.records.ChangeSet[parseInt(ownProps.campaignId,10)]),{config:state.config,record:record||{},campaign:state.campaign,breadcrumbs:state.breadcrumbs}}function mapDispatchToProps(dispatch){return{breadcrumbsActions:(0,_redux.bindActionCreators)(breadcrumbsActions,dispatch),recordActions:(0,_redux.bindActionCreators)(recordActions,dispatch),campaignActions:(0,_redux.bindActionCreators)(campaignActions,dispatch)}}Object.defineProperty(exports,"__esModule",{value:!0});var _extends=Object.assign||function(target){for(var i=1;i<arguments.length;i++){var source=arguments[i];for(var key in source)Object.prototype.hasOwnProperty.call(source,key)&&(target[key]=source[key])}return target},_react=require("react"),_react2=_interopRequireDefault(_react),_redux=require("redux"),_reactRedux=require("react-redux"),_BreadcrumbsActions=require("state/breadcrumbs/BreadcrumbsActions"),breadcrumbsActions=_interopRequireWildcard(_BreadcrumbsActions),_RecordsActions=require("state/records/RecordsActions"),recordActions=_interopRequireWildcard(_RecordsActions),_CampaignActions=require("state/campaign/CampaignActions"),campaignActions=_interopRequireWildcard(_CampaignActions),_SilverStripeComponent=require("lib/SilverStripeComponent"),_SilverStripeComponent2=_interopRequireDefault(_SilverStripeComponent),_Accordion=require("components/Accordion/Accordion"),_Accordion2=_interopRequireDefault(_Accordion),_AccordionBlock=require("components/Accordion/AccordionBlock"),_AccordionBlock2=_interopRequireDefault(_AccordionBlock),_ListGroupItem=require("components/ListGroup/ListGroupItem"),_ListGroupItem2=_interopRequireDefault(_ListGroupItem),_Toolbar=require("components/Toolbar/Toolbar"),_Toolbar2=_interopRequireDefault(_Toolbar),_FormAction=require("components/FormAction/FormAction"),_FormAction2=_interopRequireDefault(_FormAction),_CampaignAdminItem=require("./CampaignAdminItem"),_CampaignAdminItem2=_interopRequireDefault(_C
case _RecordsActionTypes2["default"].DELETE_RECORD:return(0,_deepFreeze2["default"])(_extends({},state,{}));case _RecordsActionTypes2["default"].FETCH_RECORDS_REQUEST:return state;case _RecordsActionTypes2["default"].FETCH_RECORDS_FAILURE:return state;case _RecordsActionTypes2["default"].FETCH_RECORDS_SUCCESS:return recordType=action.payload.recordType,records=action.payload.data._embedded[recordType+"s"]||{},records=records.reduce(function(prev,val){return _extends({},prev,_defineProperty({},val.ID,val))},{}),(0,_deepFreeze2["default"])(_extends({},state,_defineProperty({},recordType,records)));case _RecordsActionTypes2["default"].FETCH_RECORD_REQUEST:return state;case _RecordsActionTypes2["default"].FETCH_RECORD_FAILURE:return state;case _RecordsActionTypes2["default"].FETCH_RECORD_SUCCESS:return recordType=action.payload.recordType,record=action.payload.data,(0,_deepFreeze2["default"])(_extends({},state,_defineProperty({},recordType,_extends({},state[recordType],_defineProperty({},record.ID,record)))));case _RecordsActionTypes2["default"].DELETE_RECORD_REQUEST:return state;case _RecordsActionTypes2["default"].DELETE_RECORD_FAILURE:return state;case _RecordsActionTypes2["default"].DELETE_RECORD_SUCCESS:return recordType=action.payload.recordType,records=state[recordType],records=Object.keys(records).reduce(function(result,key){return parseInt(key,10)!==parseInt(action.payload.id,10)?_extends({},result,_defineProperty({},key,records[key])):result},{}),(0,_deepFreeze2["default"])(_extends({},state,_defineProperty({},recordType,records)));default:return state}}Object.defineProperty(exports,"__esModule",{value:!0});var _extends=Object.assign||function(target){for(var i=1;i<arguments.length;i++){var source=arguments[i];for(var key in source)Object.prototype.hasOwnProperty.call(source,key)&&(target[key]=source[key])}return target},_deepFreeze=require("deep-freeze"),_deepFreeze2=_interopRequireDefault(_deepFreeze),_RecordsActionTypes=require("./RecordsActionTypes"),_RecordsActionTypes2=_interopRequireDefault(_RecordsActionTypes),initialState={};exports["default"]=recordsReducer},{"./RecordsActionTypes":23,"deep-freeze":"deep-freeze"}],26:[function(require,module,exports){"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var ACTION_TYPES={SET_SCHEMA:"SET_SCHEMA"};exports["default"]=ACTION_TYPES},{}],27:[function(require,module,exports){"use strict";function _interopRequireDefault(obj){return obj&&obj.__esModule?obj:{"default":obj}}function _defineProperty(obj,key,value){return key in obj?Object.defineProperty(obj,key,{value:value,enumerable:!0,configurable:!0,writable:!0}):obj[key]=value,obj}function schemaReducer(){var state=arguments.length<=0||void 0===arguments[0]?initialState:arguments[0],action=arguments.length<=1||void 0===arguments[1]?null:arguments[1];switch(action.type){case _SchemaActionTypes2["default"].SET_SCHEMA:var id=action.payload.schema.schema_url;return(0,_deepFreeze2["default"])(_extends({},state,_defineProperty({},id,action.payload)));default:return state}}Object.defineProperty(exports,"__esModule",{value:!0});var _extends=Object.assign||function(target){for(var i=1;i<arguments.length;i++){var source=arguments[i];for(var key in source)Object.prototype.hasOwnProperty.call(source,key)&&(target[key]=source[key])}return target};exports["default"]=schemaReducer;var _deepFreeze=require("deep-freeze"),_deepFreeze2=_interopRequireDefault(_deepFreeze),_SchemaActionTypes=require("./SchemaActionTypes"),_SchemaActionTypes2=_interopRequireDefault(_SchemaActionTypes),initialState=(0,_deepFreeze2["default"])({})},{"./SchemaActionTypes":26,"deep-freeze":"deep-freeze"}],28:[function(require,module,exports){function cleanUpNextTick(){draining=!1,currentQueue.length?queue=currentQueue.concat(queue):queueIndex=-1,queue.length&&drainQueue()}function drainQueue(){if(!draining){var timeout=setTimeout(cleanUpNextTick);draining=!0;for(var len=queue.length;len;){for(currentQueue=queue,queue=[];++queueIndex<len;)currentQueue&&currentQueue[queueIndex].run();queueIndex=-1,len=queue.length}currentQueue=null,draining=
return"[object RegExp]"===Object.prototype.toString.call(obj)},exports.isBuffer=function(obj){return null===obj||"undefined"==typeof obj?!1:!!(obj.constructor&&obj.constructor.isBuffer&&obj.constructor.isBuffer(obj))}},{}],36:[function(require,module,exports){"use strict";function _toConsumableArray(arr){if(Array.isArray(arr)){for(var i=0,arr2=Array(arr.length);i<arr.length;i++)arr2[i]=arr[i];return arr2}return Array.from(arr)}function _typeof(obj){return obj&&"undefined"!=typeof Symbol&&obj.constructor===Symbol?"symbol":typeof obj}function getLogLevel(level,action,payload,type){switch("undefined"==typeof level?"undefined":_typeof(level)){case"object":return"function"==typeof level[type]?level[type].apply(level,_toConsumableArray(payload)):level[type];case"function":return level(action);default:return level}}function createLogger(){function printBuffer(){logBuffer.forEach(function(logEntry,key){var started=logEntry.started,startedTime=logEntry.startedTime,action=logEntry.action,prevState=logEntry.prevState,error=logEntry.error,took=logEntry.took,nextState=logEntry.nextState,nextEntry=logBuffer[key+1];nextEntry&&(nextState=nextEntry.prevState,took=nextEntry.started-started);var formattedAction=actionTransformer(action),isCollapsed="function"==typeof collapsed?collapsed(function(){return nextState},action):collapsed,formattedTime=formatTime(startedTime),titleCSS=colors.title?"color: "+colors.title(formattedAction)+";":null,title="action "+(timestamp?formattedTime:"")+" "+formattedAction.type+" "+(duration?"(in "+took.toFixed(2)+" ms)":"");try{isCollapsed?colors.title?logger.groupCollapsed("%c "+title,titleCSS):logger.groupCollapsed(title):colors.title?logger.group("%c "+title,titleCSS):logger.group(title)}catch(e){logger.log(title)}var prevStateLevel=getLogLevel(level,formattedAction,[prevState],"prevState"),actionLevel=getLogLevel(level,formattedAction,[formattedAction],"action"),errorLevel=getLogLevel(level,formattedAction,[error,prevState],"error"),nextStateLevel=getLogLevel(level,formattedAction,[nextState],"nextState");prevStateLevel&&(colors.prevState?logger[prevStateLevel]("%c prev state","color: "+colors.prevState(prevState)+"; font-weight: bold",prevState):logger[prevStateLevel]("prev state",prevState)),actionLevel&&(colors.action?logger[actionLevel]("%c action","color: "+colors.action(formattedAction)+"; font-weight: bold",formattedAction):logger[actionLevel]("action",formattedAction)),error&&errorLevel&&(colors.error?logger[errorLevel]("%c error","color: "+colors.error(error,prevState)+"; font-weight: bold",error):logger[errorLevel]("error",error)),nextStateLevel&&(colors.nextState?logger[nextStateLevel]("%c next state","color: "+colors.nextState(nextState)+"; font-weight: bold",nextState):logger[nextStateLevel]("next state",nextState));try{logger.groupEnd()}catch(e){logger.log("—— log end ——")}}),logBuffer.length=0}var options=arguments.length<=0||void 0===arguments[0]?{}:arguments[0],_options$level=options.level,level=void 0===_options$level?"log":_options$level,_options$logger=options.logger,logger=void 0===_options$logger?console:_options$logger,_options$logErrors=options.logErrors,logErrors=void 0===_options$logErrors?!0:_options$logErrors,collapsed=options.collapsed,predicate=options.predicate,_options$duration=options.duration,duration=void 0===_options$duration?!1:_options$duration,_options$timestamp=options.timestamp,timestamp=void 0===_options$timestamp?!0:_options$timestamp,transformer=options.transformer,_options$stateTransfo=options.stateTransformer,stateTransformer=void 0===_options$stateTransfo?function(state){return state}:_options$stateTransfo,_options$actionTransf=options.actionTransformer,actionTransformer=void 0===_options$actionTransf?function(actn){return actn}:_options$actionTransf,_options$errorTransfo=options.errorTransformer,errorTransformer=void 0===_options$errorTransfo?function(error){return error}:_options$errorTransfo,_options$colors=options.colors,colors=void 0===_options$colors?{title:function(){return"#000000"},prevState:function(){return"#9E9E9E"},action:function(){ret
2016-04-07 13:43:43 +02:00
//# sourceMappingURL=bundle-framework.js.map