<commit_before>var Backbone = require('backbone');

var View = Backbone.View.extend({
    initialize: function(options) {
        options = options || {};
        if (options.vent) {
            this.vent = options.vent;
            this.applyBindings();
        }
        this.timeout = options.timeout || 7500;
    },

    applyBindings: function() {
        this.listenTo(this.vent, 'notification', this.notify, this);
    },

    notify: function(notification) {
        var level = notification.level || 'info';

        var node = $("<div class='notification'></div>").addClass(level);
        node.html(notification.message);

        var close = $('<a><i class="icon-remove-sign"></i></a>');
        close.on('click', function() {
            node.slideUp(function() {
                node.remove();
            }, 100);
        });
<commit_msg>ADMINUI-1636 dismiss notification button does not function properly<commit_after>var Backbone = require('backbone');

var View = Backbone.View.extend({
    initialize: function(options) {
        options = options || {};
        if (options.vent) {
            this.vent = options.vent;
            this.applyBindings();
        }
        this.timeout = options.timeout || 7500;
    },

    applyBindings: function() {
        this.listenTo(this.vent, 'notification', this.notify, this);
    },

    notify: function(notification) {
        var level = notification.level || 'info';

        var node = $("<div class='notification'></div>").addClass(level);
        node.html(notification.message);

        var close = $('<a><i class="icon-remove-sign"></i></a>');
        close.on('click', function() {
            node.remove();
        });

{'fraction_non_alphanumeric': 0.1626399528579847, 'fraction_numerical': 0.00883912787271656, 'mean_word_length': 2.3294117647058825, 'pattern_counts': {'":': 0, '<': 15, '<?xml version=': 0, '>': 15, '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': '7120836', 'n_tokens_mistral': 484, 'n_tokens_neox': 463, 'n_words': 93}