diff --git a/styles/container.scss b/styles/container.scss deleted file mode 100644 index afba395..0000000 --- a/styles/container.scss +++ /dev/null @@ -1,49 +0,0 @@ -/* - -MIT License - -Copyright (c) 2023 Valery Zinchenko - -Permission is hereby granted, free of charge, to any person obtaining a copy -of this software and associated documentation files (the "Software"), to deal -in the Software without restriction, including without limitation the rights -to use, copy, modify, merge, publish, distribute, sublicense, and/or sell -copies of the Software, and to permit persons to whom the Software is -furnished to do so, subject to the following conditions: - -The above copyright notice and this permission notice shall be included in all -copies or substantial portions of the Software. - -*/ - -.modal { - position: fixed; - inset: 0; - z-index: 1; - transition: 250ms ease-in-out opacity; - - &:not(&--active) { - opacity: 0; - pointer-events: none; - } -} - -.modal__container { - position: absolute; - inset: 0; - - display: grid; - background: rgba(#1E202E, 0.9); - cursor: pointer; - - overflow: auto; - overscroll-behavior: contain; - - .modal:not(.modal--active) & { - overflow: hidden; - } -} - -.modal__inner { - display: grid; -} \ No newline at end of file diff --git a/styles/modal.scss b/styles/modal.scss index 67feb28..0569d56 100644 --- a/styles/modal.scss +++ b/styles/modal.scss @@ -1,2 +1,49 @@ -@import "./container.scss"; -@import "./layouts.scss"; \ No newline at end of file +/* + +MIT License + +Copyright (c) 2023 Valery Zinchenko + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +*/ + +.modal { + position: fixed; + inset: 0; + z-index: 1; + transition: 250ms ease-in-out opacity; + + &:not(&--active) { + opacity: 0; + pointer-events: none; + } +} + +.modal__container { + position: absolute; + inset: 0; + + display: grid; + background: rgba(#1E202E, 0.9); + cursor: pointer; + + overflow: auto; + overscroll-behavior: contain; + + .modal:not(.modal--active) & { + overflow: hidden; + } +} + +.modal__inner { + display: grid; +}