<commit_before>Ext.application({
	requires : [ 'Ext.container.Viewport' ],
	name : 'Datanium',
	appFolder : '../js/app',
	controllers : [ 'Homepage', 'FieldController', 'GridController', 'ChartController', 'AnalysisController' ],

	init : function() {
		Ext.enableFx = true;
	},

	launch : function() {
		Ext.create('Ext.panel.Panel', {
			layout : 'border',
			// renderTo : Ext.getBody(),
			renderTo : Ext.get('appContainer'),
			bodyBorder : false,
			bodyStyle : {
				'position' : 'relative',
				'z-index' : 1
			},
			defaults : {
				collapsible : true,
				border : false,
				split : true
			},
			id : "appPanel",
			listeners : {
				beforerender : function() {
					this.setHeight(Ext.get("appContainer").getHeight());
					this.doLayout();
				}
			},
			/*
			 * items : [ { region : 'center', xtype : 'tabpanel', id :
			 * 'mainBox', activeTab : 0, collapsible : false, header : false,
			 * tabBar : { display : false, height : 25, defaults : { height : 25 } },
			 * items : [ { itemId : 'report-tab' + Datanium.GlobalData.tabindex,
			 * closable : true, // icon : 'img/icons/report.png', title : 'My
			 * Analysis', xtype : 'reporttemplate' } ] } ],
			 */
			items : [ {
				region : 'center',
				id : 'mainBox',
				header : false,
				title : 'My Analysis',
				xtype : 'reporttemplate'
			} ]
		});
		Ext.EventManager.onWindowResize(function() {
			Ext.getCmp("appPanel").setHeight(Ext.get("appContainer").getHeight());
			Ext.getCmp("appPanel").doLayout();
		});
		this.getController('GridController').generateRpt();
		// call report generate when existed report is loaded
		if (Datanium.GlobalData.hashid != null && Datanium.GlobalData.hashid !== '') {
			Datanium.util.CommonUtils.getCmpInActiveTab('elementPanel').fireEvent('refreshElementPanel');
			Datanium.util.CommonUtils.updateFilterFields();
			Datanium.util.CommonUtils.getCmpInActiveTab('elementPanel').fireEvent('selectionChange');
			this.getController('ChartController').reloadFilterSwitchMenu();
			if (Datanium.GlobalData.rptMode === 'grid') {
				Ext.getCmp('gridViewBtn').toggle(true);
			}
			if (Datanium.GlobalData.rptMode === 'chart') {
				Ext.getCmp('chartViewBtn').toggle(true);
			}
			if (Datanium.GlobalData.rptMode === 'analysis') {
				Ext.getCmp('analysisViewBtn').toggle(true);
			}
		}
	}
});<commit_msg>minor fix<commit_after>Ext.application({
	requires : [ 'Ext.container.Viewport' ],
	name : 'Datanium',
	appFolder : '../js/app',
	controllers : [ 'Homepage', 'FieldController', 'GridController', 'ChartController', 'AnalysisController' ],

	init : function() {
		Ext.enableFx = true;
	},

	launch : function() {
		Ext.create('Ext.panel.Panel', {
			layout : 'border',
			// renderTo : Ext.getBody(),
			renderTo : Ext.get('appContainer'),
			bodyBorder : false,
			bodyStyle : {
				'position' : 'relative',
				'z-index' : 1
			},
			defaults : {
				collapsible : true,
				border : false,
				split : true
			},
			id : "appPanel",
			listeners : {
				beforerender : function() {
					this.setHeight(Ext.get("appContainer").getHeight());
					this.doLayout();
				}
			},
			/*
			 * items : [ { region : 'center', xtype : 'tabpanel', id :
			 * 'mainBox', activeTab : 0, collapsible : false, header : false,
			 * tabBar : { display : false, height : 25, defaults : { height : 25 } },
			 * items : [ { itemId : 'report-tab' + Datanium.GlobalData.tabindex,
			 * closable : true, // icon : 'img/icons/report.png', title : 'My
			 * Analysis', xtype : 'reporttemplate' } ] } ],
			 */
			items : [ {
				region : 'center',
				id : 'mainBox',
				header : false,
				title : 'My Analysis',
				xtype : 'reporttemplate'
			} ]
		});
		Ext.EventManager.onWindowResize(function() {
			Ext.getCmp("appPanel").setHeight(Ext.get("appContainer").getHeight());
			Ext.getCmp("appPanel").doLayout();
		});
		// call report generate when existed report is loaded
		if (Datanium.GlobalData.hashid != null && Datanium.GlobalData.hashid !== '') {
			Datanium.util.CommonUtils.getCmpInActiveTab('elementPanel').fireEvent('refreshElementPanel');
			Datanium.util.CommonUtils.updateFilterFields();
			Datanium.util.CommonUtils.getCmpInActiveTab('elementPanel').fireEvent('selectionChange');
			this.getController('ChartController').reloadFilterSwitchMenu();
			if (Datanium.GlobalData.rptMode === 'grid') {
				Ext.getCmp('gridViewBtn').toggle(true);
			}
			if (Datanium.GlobalData.rptMode === 'chart') {
				Ext.getCmp('chartViewBtn').toggle(true);
			}
			if (Datanium.GlobalData.rptMode === 'analysis') {
				Ext.getCmp('analysisViewBtn').toggle(true);
			}
		} else {
			this.getController('GridController').generateRpt();
		}
	}
});
{'fraction_non_alphanumeric': 0.17578629900904783, 'fraction_numerical': 0.0025850926324859974, 'mean_word_length': 3.5341796875, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '3800156', 'n_tokens_mistral': 1798, 'n_tokens_neox': 1492, 'n_words': 252}