Pure Text Copy

This script disables the automatic source insertion function when copying text.

You will need to install an extension such as Tampermonkey, Greasemonkey or Violentmonkey to install this script.

You will need to install an extension such as Tampermonkey or Violentmonkey to install this script.

You will need to install an extension such as Tampermonkey or Violentmonkey to install this script.

You will need to install an extension such as Tampermonkey or Userscripts to install this script.

You will need to install an extension such as Tampermonkey to install this script.

You will need to install a user script manager extension to install this script.

(I already have a user script manager, let me install it!)

You will need to install an extension such as Stylus to install this style.

You will need to install an extension such as Stylus to install this style.

ستحتاج إلى تثبيت إضافة مثل Stylus لتثبيت هذا النمط.

ستحتاج إلى تثبيت إضافة لإدارة أنماط المستخدم لتتمكن من تثبيت هذا النمط.

ستحتاج إلى تثبيت إضافة لإدارة أنماط المستخدم لتثبيت هذا النمط.

ستحتاج إلى تثبيت إضافة لإدارة أنماط المستخدم لتثبيت هذا النمط.

(لدي بالفعل مثبت أنماط للمستخدم، دعني أقم بتثبيته!)

// ==UserScript==
// @name         Pure Text Copy
// @namespace    Pure Text Copy
// @version      1.0.0
// @description  This script disables the automatic source insertion function when copying text.
// @author       DumbGPT
// @match        *://*/*
// @grant        none
// ==/UserScript==

(function() {
    'use strict';
    
    document.addEventListener('copy', function(event) {
        const selection = window.getSelection();
        
        if (selection && selection.toString().length > 0) {
            event.preventDefault();
            
            const pureText = selection.toString();
            
            event.clipboardData.setData('text/plain', pureText);
        }
    }, true);
    
    function showCopyNotification() {
        const notification = document.createElement('div');
        
        const container = document.createElement('div');
        container.style.cssText = 'display: flex; align-items: center;';
        
        const icon = document.createElement('span');
        icon.innerHTML = '✓';
        icon.style.cssText = 'display: inline-flex; align-items: center; justify-content: center; width: 20px; height: 20px; background-color: #4CAF50; border-radius: 50%; margin-right: 10px; font-size: 12px; color: white;';
        
        const text = document.createElement('span');
        text.textContent = 'Text Copied';
        text.style.cssText = 'font-family: "Segoe UI", Arial, sans-serif; font-weight: 500;';
        
        container.appendChild(icon);
        container.appendChild(text);
        notification.appendChild(container);
        
        notification.style.cssText = `
            position: fixed;
            bottom: 20px;
            right: 20px;
            background-color: rgba(255, 255, 255, 0.95);
            color: #333;
            padding: 12px 16px;
            border-radius: 8px;
            box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
            z-index: 9999;
            opacity: 0;
            transform: translateY(10px);
            transition: opacity 0.3s, transform 0.3s;
        `;
        
        document.body.appendChild(notification);
        
        setTimeout(() => {
            notification.style.opacity = '1';
            notification.style.transform = 'translateY(0)';
        }, 10);
        
        setTimeout(() => {
            notification.style.opacity = '0';
            notification.style.transform = 'translateY(10px)';
            setTimeout(() => {
                document.body.removeChild(notification);
            }, 300);
        }, 2000);
    }
    
    document.addEventListener('copy', () => showCopyNotification(), false);
})();