<commit_before>﻿/* Bootstrap datetimepicker extension */
/* Build with http://eonasdan.github.io/bootstrap-datetimepicker */

Aspectize.Extend("BootstrapDateTimePicker", {
    Properties: { Value: null, MinDate: null, MaxDate: null, Stepping: 1, Format: '' },
    Events: ['OnValueChanged'],
    Init: function (elem) {

        function newPicker() {
            var options = {
                minDate: Aspectize.UiExtensions.GetProperty(elem, 'MinDate') || false,
                maxDate: Aspectize.UiExtensions.GetProperty(elem, 'MaxDate') || false,
                stepping: Aspectize.UiExtensions.GetProperty(elem, 'Stepping') || 1,
                format: Aspectize.UiExtensions.GetProperty(elem, 'Format') || 'DD/MM/YYYY HH:mm'
            };

            $(elem).datetimepicker(options).on('dp.change', function (e) {
                Aspectize.UiExtensions.ChangeProperty(elem, 'Value', e.date.toDate());
            });
        }

        Aspectize.UiExtensions.AddMergedPropertyChangeObserver(elem, function (sender, arg) {

            if ('Value' in arg) {
                $(sender).datetimepicker('date', arg.Value);
            }

            if ('MinDate' in arg) {
                var mindate = arg.MinDate || false;
                $(sender).data("DateTimePicker").minDate(mindate);
            }

            if ('MaxDate' in arg) {
                var maxdate = arg.MaxDate || false;
                $(sender).data("DateTimePicker").maxDate(maxdate);
            }

            if ('Stepping' in arg) {
                var stepping = arg.Stepping || 1;
                $(sender).data("DateTimePicker").stepping(stepping);
            }

            if ('Format' in arg) {
                var format = arg.Format || 'DD/MM/YYYY HH:mm';
                $(sender).data("DateTimePicker").format(format);
            }

        });
<commit_msg>inline<commit_after>﻿/* Bootstrap datetimepicker extension */
/* Build with http://eonasdan.github.io/bootstrap-datetimepicker */

Aspectize.Extend("BootstrapDateTimePicker", {
    Properties: { Value: null, MinDate: null, MaxDate: null, Stepping: 1, Format: '', Inline: false },
    Events: ['OnValueChanged'],
    Init: function (elem) {

        function newPicker() {
            var options = {
                minDate: Aspectize.UiExtensions.GetProperty(elem, 'MinDate') || false,
                maxDate: Aspectize.UiExtensions.GetProperty(elem, 'MaxDate') || false,
                stepping: Aspectize.UiExtensions.GetProperty(elem, 'Stepping') || 1,
                format: Aspectize.UiExtensions.GetProperty(elem, 'Format') || 'DD/MM/YYYY HH:mm',
                inline: Aspectize.UiExtensions.GetProperty(elem, 'Inline') || false
            };

            if ($(elem).data("DateTimePicker")) {
                $(elem).data("DateTimePicker").destroy();
            }

            $(elem).datetimepicker(options).on('dp.change', function (e) {
                Aspectize.UiExtensions.ChangeProperty(elem, 'Value', e.date.toDate());
            });
        }

        Aspectize.UiExtensions.AddMergedPropertyChangeObserver(elem, function (sender, arg) {

            if ('Value' in arg) {
                $(sender).datetimepicker('date', arg.Value);
            }

            if ('MinDate' in arg) {
                var mindate = arg.MinDate || false;
                $(sender).data("DateTimePicker").minDate(mindate);
            }

            if ('MaxDate' in arg) {
                var maxdate = arg.MaxDate || false;
                $(sender).data("DateTimePicker").maxDate(maxdate);
            }

            if ('Stepping' in arg) {
                var stepping = arg.Stepping || 1;
                $(sender).data("DateTimePicker").stepping(stepping);
            }

            if ('Format' in arg) {
                var format = arg.Format || 'DD/MM/YYYY HH:mm';
                $(sender).data("DateTimePicker").format(format);
            }

            if ('Inline' in arg) {
                $(sender).data("DateTimePicker").inline(arg.Inline || false);
            }

            newPicker();
        });

{'fraction_non_alphanumeric': 0.14313677514068998, 'fraction_numerical': 0.0014680694886224615, 'mean_word_length': 1.9262705798138868, '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': '135752', 'n_tokens_mistral': 1145, 'n_tokens_neox': 1085, 'n_words': 210}