aboutsummaryrefslogtreecommitdiff
path: root/content/overview-code-blocks.md
diff options
context:
space:
mode:
authorJieiku2023-05-22 23:09:27 -0700
committerJieiku2023-05-22 23:09:27 -0700
commit9543caf10ffdbcc2cea462a8bcb64cee29d406d5 (patch)
treee82f984f8b5649336016d62607dcf2b5292f0ee1 /content/overview-code-blocks.md
parentd9fb3248650404ad6d078eba39b8b91381b1ebed (diff)
downloadabridge-9543caf10ffdbcc2cea462a8bcb64cee29d406d5.tar.gz
abridge-9543caf10ffdbcc2cea462a8bcb64cee29d406d5.tar.bz2
abridge-9543caf10ffdbcc2cea462a8bcb64cee29d406d5.zip
Syntax Highlighting Variables
Diffstat (limited to 'content/overview-code-blocks.md')
-rw-r--r--content/overview-code-blocks.md57
1 files changed, 57 insertions, 0 deletions
diff --git a/content/overview-code-blocks.md b/content/overview-code-blocks.md
index d38ac9e..916dcc1 100644
--- a/content/overview-code-blocks.md
+++ b/content/overview-code-blocks.md
@@ -320,3 +320,60 @@ while True:
print("Could Not Connect to SMTP server!")
time.sleep(interval)
```
+
+### Ruby
+```ruby
+=begin
+ Ruby program to check whether the
+ year is leap year or not between range.
+=end
+
+puts "Enter the lower limit:"
+lwr = gets.chomp.to_i
+puts "Enter the upper limit:"
+upr = gets.chomp.to_i
+
+for yr in lwr..upr do
+ if yr % 400 == 0
+ puts "#{yr} is a leap year"
+ elsif yr % 4 == 0 && yr % 100 !=0
+ puts "#{yr} is a leap year"
+ else
+ puts "#{yr} is not a leap year"
+ end
+end
+```
+
+### SCSS
+```scss
+
+$font: "Roboto", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "Oxygen", "Ubuntu", "Cantarell", "Fira Sans", "Droid Sans", "Helvetica Neue", "Noto Sans", Helvetica, Arial, sans-serif !default;
+$font-mono: ui-monospace, Menlo, Monaco, Consolas, "SF Mono", "Cascadia Mono", "Segoe UI Mono", "DejaVu Sans Mono", "Liberation Mono", "Roboto Mono", "Oxygen Mono", "Ubuntu Monospace", "Ubuntu Mono", "Source Code Pro", "Fira Mono", "Droid Sans Mono", "Courier New", Courier, monospace !default;
+
+@mixin root {
+ #{--ff}: $font;
+ #{--fm}: $font-mono;//code
+
+ --fs: 1rem; //font-size
+
+ // Responsive typography
+ @if $enable-responsive-typography {
+ @if map-get($breakpoints, "lg") {
+ @media (min-width: map-get($breakpoints, "lg")) {
+ --fs: 1.08rem;
+ }
+ }
+ }
+}
+```
+
+### CSS
+```css
+html {
+ font-size: var(--fs);
+}
+
+.c {
+ text-align: center;
+}
+```