{"id":23114057,"url":"https://github.com/abkarim/stealthseminar-24hour-timer","last_synced_at":"2025-04-04T00:26:56.533Z","repository":{"id":130932253,"uuid":"559295639","full_name":"abkarim/stealthseminar-24hour-timer","owner":"abkarim","description":"JavaScript code for showing timer","archived":false,"fork":false,"pushed_at":"2022-11-22T17:29:36.000Z","size":18,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-02-09T12:27:49.790Z","etag":null,"topics":["stealthseminar","timer-clock"],"latest_commit_sha":null,"homepage":"","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/abkarim.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2022-10-29T17:06:58.000Z","updated_at":"2023-01-11T10:36:20.000Z","dependencies_parsed_at":"2023-04-20T12:48:29.294Z","dependency_job_id":null,"html_url":"https://github.com/abkarim/stealthseminar-24hour-timer","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/abkarim%2Fstealthseminar-24hour-timer","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/abkarim%2Fstealthseminar-24hour-timer/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/abkarim%2Fstealthseminar-24hour-timer/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/abkarim%2Fstealthseminar-24hour-timer/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/abkarim","download_url":"https://codeload.github.com/abkarim/stealthseminar-24hour-timer/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":247101053,"owners_count":20883700,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["stealthseminar","timer-clock"],"created_at":"2024-12-17T03:18:34.273Z","updated_at":"2025-04-04T00:26:56.528Z","avatar_url":"https://github.com/abkarim.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# 24 hour timer\n\nAdd 24 hour timer in StealthSeminar registration page. But you have the option to **reduce or increase hours**. This timer is static, page refresh will reset the timer to default time.\n\n![App Screenshot](screenshot.png)\n\n## Usage\n\nwe will add custom javascript.\n\n[ official doc about how to add custom javascript? ](https://help.stealthseminarapp.com/en/articles/2802201-custom-javascript)\n\nUse the \"Tracking Code Setup\" in **\"Miscellaneous\"** menu, then click **\"Tracking Code Setup\"**.\nWe want to show timer in registration page so find **\"Registration Page\"** (you can use another option, if you want).\nWe will add our JavaScript code in the last field **BOTTOM OF PAGE** box.\n\nIf you want to edit something it is recommended that you first do editing the script.js file and then add it to the input.\n\n```javascript\n\u003cscript\u003e\n// ... script.js file content paste here\n\u003c/script\u003e\n```\n\nThen click **save**. \\*By default this file will append timer as **first child on body.\\***\nBut you have the option to change this behavior.\n\n## How to change parent element of timer\n\nSet parent selector in parentId\n\n```javascript\nconst parentId = null; // element to append timer\n//...\n```\n\nTO\n\n```javascript\nconst parentId = \"query selector here\"; // element to append timer\n//...\n```\n\n## Change style\n\nFind following code and edit in script.js\n\n```javascript\n//...\n// Styles\nconst styles = `\n    /*Container */\n    #ss-24-hour-timer-container {\n        display: flex;\n        gap: 1rem;\n        background-color: white;\n        width: 100%;\n        align-items: center;\n        justify-content: center;\n        padding-top: 1rem;\n        padding-bottom: 1rem;\n    }\n    /* Number */\n    #ss-24-hour-timer-container .hour,\n    #ss-24-hour-timer-container .minute,\n    #ss-24-hour-timer-container .second\n    {\n        background-color: #1a9dd1;\n        border-radius: 0.1rem;\n        color: white;\n        display: inline-block;\n        font-size: 2.5rem;\n        padding: 1rem;\n    }\n    /* Text */\n    #ss-24-hour-timer-container .text\n    {\n        color:  #202020;\n        font-size: 0.8rem;\n        letter-spacing: 0.1rem;\n        margin-top: 0.1rem;\n        text-align: center;\n    }\n`;\n//...\n```\n\n## Change Hours\n\nFind following code and edit in script.js. When using number less than 10, add a '0' before and place between quotes(') number, EX: '05'.\nBy the way hours can be bigger than 24.\n\n```javascript\n//...\nconst hour_number = createElement('span', 24, 'hour', hourElement); // Hours in second parameter\n//...\n```\n\n## Change Text\n\nFind following code and edit in script.js to change text. Text placed on the second parameter of createElement function\n\n```javascript\n//...\nconst hour_text = createElement('div', 'HOURS', 'text', hourElement); // Hour\nconst minute_text = createElement('div', 'MINUTES', 'text', minuteElement); // Minute\nconst second_text = createElement('div', 'SECONDS', 'text', secondElement); // Second\n//...\n```","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fabkarim%2Fstealthseminar-24hour-timer","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fabkarim%2Fstealthseminar-24hour-timer","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fabkarim%2Fstealthseminar-24hour-timer/lists"}